fix: guard transcript sandbox subscription
This commit is contained in:
@@ -32,7 +32,13 @@ export function SandboxViolationExpandedView() {
|
||||
let t2;
|
||||
if ($[1] === Symbol.for("react.memo_cache_sentinel")) {
|
||||
t1 = () => {
|
||||
if (!SandboxManager.isSandboxingEnabled() || getPlatform() === "linux") {
|
||||
return;
|
||||
}
|
||||
const store = SandboxManager.getSandboxViolationStore();
|
||||
if (!store || typeof store.subscribe !== "function") {
|
||||
return;
|
||||
}
|
||||
const unsubscribe = store.subscribe(allViolations => {
|
||||
setViolations(allViolations.slice(-10));
|
||||
setTotalCount(store.getTotalCount());
|
||||
|
||||
Reference in New Issue
Block a user