mirror of https://github.com/xwiki-labs/cryptpad
Hide password change form for SSO accounts when cp password disabled
This commit is contained in:
parent
72cb827e18
commit
1b032a06de
|
@ -662,6 +662,7 @@ define([
|
|||
|
||||
create['change-password'] = function() {
|
||||
if (!common.isLoggedIn()) { return; }
|
||||
if (privateData.isSSO && ApiConfig.sso && ApiConfig.sso.password === 0) { return; }
|
||||
|
||||
var $div = $('<div>', { 'class': 'cp-settings-change-password cp-sidebarlayout-element' });
|
||||
|
||||
|
|
|
@ -150,8 +150,9 @@ define([
|
|||
category = window.location.hash.slice(1);
|
||||
window.location.hash = '';
|
||||
}
|
||||
var addData = function (obj) {
|
||||
var addData = function (obj, Cryptpad, user, Utils) {
|
||||
if (category) { obj.category = category; }
|
||||
obj.isSSO = Boolean(Utils.LocalStore.getSSOSeed());
|
||||
};
|
||||
SFCommonO.start({
|
||||
noRealtime: true,
|
||||
|
|
Loading…
Reference in New Issue