don't send permissions update if permissions have not changed
This commit is contained in:
+7
-2
@@ -751,8 +751,10 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
handleSubmit: function() {
|
handleSubmit: function() {
|
||||||
var mode = this.state.mode || "N";
|
// Normalize string, otherwise cannot check if mode has changed.
|
||||||
if (mode !== this.props.mode) {
|
var mode = (this.state.mode || "N").split('').sort().join('');
|
||||||
|
var before = (this.props.mode || "N").split('').sort().join('')
|
||||||
|
if (mode !== before) {
|
||||||
this.props.onSubmit(mode);
|
this.props.onSubmit(mode);
|
||||||
} else {
|
} else {
|
||||||
this.props.onCancel();
|
this.props.onCancel();
|
||||||
@@ -1813,6 +1815,9 @@
|
|||||||
}
|
}
|
||||||
// Redraw without the deleted topic.
|
// Redraw without the deleted topic.
|
||||||
this.resetContactList();
|
this.resetContactList();
|
||||||
|
} else if (what === "acs") {
|
||||||
|
// Permissions changed.
|
||||||
|
console.log("app: permissions changed");
|
||||||
} else {
|
} else {
|
||||||
// TODO(gene): handle other types of notifications:
|
// TODO(gene): handle other types of notifications:
|
||||||
// * ua -- user agent changes (may display a pictogram for mobile/desktop)
|
// * ua -- user agent changes (may display a pictogram for mobile/desktop)
|
||||||
|
|||||||
Reference in New Issue
Block a user