fixies
This commit is contained in:
parent
20299450c7
commit
b29dc2971c
@ -2,12 +2,12 @@ import { getOwner } from "discourse-common/lib/get-owner";
|
||||
import deprecated from "discourse-common/lib/deprecated";
|
||||
|
||||
deprecated(
|
||||
"`discourse/lib/mobile` import is deprecated. Use `isMobileDevice`, `mobileView`, properties and `toggleMobileView` method on `site:service`."
|
||||
"`discourse/lib/mobile` import is deprecated. Use `isMobileDevice`, `mobileView`, properties and `toggleMobileView` method on `service:site`."
|
||||
);
|
||||
|
||||
function site() {
|
||||
// Use the "default owner"
|
||||
return getOwner().lookup("site:service");
|
||||
return getOwner().lookup("service:site");
|
||||
}
|
||||
|
||||
const Mobile = {
|
||||
|
||||
@ -308,12 +308,13 @@ export function acceptance(name, optionsOrCallback) {
|
||||
}
|
||||
this.siteSettings = currentSettings();
|
||||
|
||||
resetSite(currentSettings(), siteChanges);
|
||||
|
||||
if (mobileView) {
|
||||
Site.current().mobileView = true;
|
||||
siteChanges ||= {};
|
||||
siteChanges.mobileView = true;
|
||||
}
|
||||
|
||||
resetSite(currentSettings(), siteChanges);
|
||||
|
||||
this.container = getOwner(this);
|
||||
|
||||
if (!this.owner) {
|
||||
|
||||
Reference in New Issue
Block a user