mirror of
https://github.com/hensm/fx_cast.git
synced 2026-06-10 01:29:58 +00:00
TSLint compliance
This commit is contained in:
1
ext/src/global.d.ts
vendored
1
ext/src/global.d.ts
vendored
@@ -8,6 +8,7 @@ declare const APPLICATION_VERSION: string;
|
||||
|
||||
|
||||
declare interface Object {
|
||||
// tslint:disable-next-line:ban-types
|
||||
wrappedJSObject: Object;
|
||||
}
|
||||
|
||||
|
||||
@@ -33,4 +33,5 @@ export function getWindowCenteredProps (
|
||||
}
|
||||
|
||||
|
||||
// tslint:disable-next-line:max-line-length
|
||||
export const REMOTE_MATCH_PATTERN_REGEX = /^(?:(?:(\*|https?|ftp):\/\/(\*|(?:\*\.(?:[^\/\*:]\.?)+(?:[^\.])|[^\/\*:]*))?)(\/.*)|<all_urls>)$/;
|
||||
|
||||
@@ -30,7 +30,9 @@ import { Callbacks
|
||||
|
||||
const _id = new WeakMap<Session, string>();
|
||||
|
||||
const _messageListeners = new WeakMap<Session, Map<string, Set<MessageListener>>>();
|
||||
const _messageListeners = new WeakMap<
|
||||
Session, Map<string, Set<MessageListener>>>();
|
||||
|
||||
const _updateListeners = new WeakMap<Session, Set<UpdateListener>>();
|
||||
|
||||
const _leaveCallbacks = new WeakMap<Session, CallbacksMap>();
|
||||
@@ -176,7 +178,9 @@ export default class Session {
|
||||
case "shim:/session/impl_setReceiverMuted": {
|
||||
const { volumeId, error } = message.data;
|
||||
const [ successCallback, errorCallback ]
|
||||
= _setReceiverMutedCallbacks.get(this).get(volumeId);
|
||||
= _setReceiverMutedCallbacks
|
||||
.get(this)
|
||||
.get(volumeId);
|
||||
|
||||
if (error && errorCallback) {
|
||||
errorCallback(new _Error(ErrorCode.SESSION_ERROR));
|
||||
|
||||
@@ -27,6 +27,7 @@ import { AutoJoinPolicy
|
||||
import media from "./media";
|
||||
|
||||
import { requestSession as requestSessionTimeout } from "../timeout";
|
||||
|
||||
import { onMessage, sendMessageResponse } from "../messageBridge";
|
||||
|
||||
|
||||
|
||||
@@ -117,7 +117,9 @@ export default class Media {
|
||||
case "shim:/media/sendMediaMessageResponse": {
|
||||
const { messageId, error } = message.data;
|
||||
const [ successCallback, errorCallback ]
|
||||
= _sendMediaMessageCallbacks.get(this).get(messageId);
|
||||
= _sendMediaMessageCallbacks
|
||||
.get(this)
|
||||
.get(messageId);
|
||||
|
||||
if (error && errorCallback) {
|
||||
errorCallback(new _Error(ErrorCode.SESSION_ERROR));
|
||||
|
||||
Reference in New Issue
Block a user