Fix refresh resources button and remove portal specific notebooks call (#123)
This commit is contained in:
parent
14ef40029d
commit
2a53dfabb5
|
@ -2,6 +2,7 @@ import { MessageTypes } from "../Contracts/ExplorerContracts";
|
|||
import Q from "q";
|
||||
import * as _ from "underscore";
|
||||
import * as Constants from "./Constants";
|
||||
import { config, Platform } from "../Config";
|
||||
|
||||
export interface CachedDataPromise<T> {
|
||||
deferred: Q.Deferred<T>;
|
||||
|
@ -59,7 +60,7 @@ export function sendMessage(data: any): void {
|
|||
}
|
||||
|
||||
export function canSendMessage(): boolean {
|
||||
return window.parent !== window;
|
||||
return config.platform === Platform.Portal && window.parent !== window;
|
||||
}
|
||||
|
||||
// TODO: This is exported just for testing. It should not be.
|
||||
|
|
|
@ -2606,7 +2606,11 @@ export default class Explorer {
|
|||
|
||||
private async _refreshNotebooksEnabledStateForAccount(): Promise<void> {
|
||||
const authType = window.authType as AuthType;
|
||||
if (authType === AuthType.EncryptedToken || authType === AuthType.ResourceToken) {
|
||||
if (
|
||||
authType === AuthType.EncryptedToken ||
|
||||
authType === AuthType.ResourceToken ||
|
||||
authType === AuthType.MasterKey
|
||||
) {
|
||||
this.isNotebooksEnabledForAccount(false);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue