Skip to content

Commit 385df0d

Browse files
Update agBuffer.js
fix stupid number decision by me
1 parent 78bf126 commit 385df0d

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

static/extensions/AndrewGaming587/agBuffer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@
9090
}
9191
constructor(source, passthrough = true) { // Passthrough will return the source if the source is already an ArrayBufferType and passthrough is true, for optimization reasons
9292
if (source == undefined || source == null) source = 0;
93-
if (passthrough && ("customId" in source && source.customId == "agBuffer")) return source;
93+
if (passthrough && (typeof source == "object" && "customId" in source && source.customId == "agBuffer")) return source;
9494
if (source instanceof Array) {
9595
// window.agBufferDebugLastType = "jsarray"
9696
// Uint8Array conversion is necessary because ArrayBuffer constructor doesn't take normal arrays as input

0 commit comments

Comments
 (0)