Fix deactivating MFA on user accounts (#2797)

This commit is contained in:
Joram Wilander
2016-04-26 08:40:47 -04:00
committed by Christopher Speller
parent 80d7debf1a
commit c2fc28aa10
2 changed files with 6 additions and 4 deletions

View File

@@ -2277,6 +2277,9 @@ func generateMfaQrCode(c *Context, w http.ResponseWriter, r *http.Request) {
}
w.Header().Del("Content-Type") // Content-Type will be set automatically by the http writer
w.Header().Set("Cache-Control", "no-cache")
w.Header().Set("Pragma", "no-cache")
w.Header().Set("Expires", "0")
w.Write(img)
}

View File

@@ -139,10 +139,9 @@ class SecurityTab extends React.Component {
);
}
deactivateMfa() {
const data = {};
data.activate = false;
Client.updateMfa(data,
Client.updateMfa(
'',
false,
() => {
this.props.updateSection('');
AsyncClient.getMe();