mirror of
https://github.com/discourse/discourse.git
synced 2024-11-22 14:38:17 +08:00
BUGFIX: do not push read-only signal to ALL sites
This commit is contained in:
parent
c8795d8aa4
commit
a682c8fc91
|
@ -28,7 +28,7 @@ Discourse.addInitializer(function() {
|
||||||
|
|
||||||
Discourse.set("isReadOnly", Discourse.Site.currentProp("is_readonly"));
|
Discourse.set("isReadOnly", Discourse.Site.currentProp("is_readonly"));
|
||||||
|
|
||||||
Discourse.MessageBus.subscribe("/global/read-only", function (enabled) {
|
Discourse.MessageBus.subscribe("/site/read-only", function (enabled) {
|
||||||
Discourse.set("isReadOnly", enabled);
|
Discourse.set("isReadOnly", enabled);
|
||||||
if (enabled) {
|
if (enabled) {
|
||||||
if (!Discourse.User.currentProp("hideReadOnlyAlert")) {
|
if (!Discourse.User.currentProp("hideReadOnlyAlert")) {
|
||||||
|
|
|
@ -208,7 +208,7 @@ module Discourse
|
||||||
end
|
end
|
||||||
|
|
||||||
def self.readonly_channel
|
def self.readonly_channel
|
||||||
"/global/read-only"
|
"/site/read-only"
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue
Block a user