Files
discord-decomp/_bundle/isString.js
T
2026-11-01 12:12:55 +02:00

22 lines
710 B
JavaScript

// Metro module 4444 (f4445).
import * as _callBoundIntrinsic from "./callBoundIntrinsic";
import * as _hasToStringTagShams from "./hasToStringTagShams";
let c2667_0 = _callBoundIntrinsic("String.prototype.valueOf");
let c2667_1 = _callBoundIntrinsic("Object.prototype.toString");
let c2667_2 = _hasToStringTagShams();
module.exports = function isString(a0) {
let r2 = typeof a0 === "string";
if (typeof a0 !== "string") {
const r1 = a0 ? typeof a0 !== "object" : !a0;
r2 = r1 ? !r1 : c2667_2 ? (function tryStringObject(a0) {
try {
c2667_0(a0);
} catch ($e) {
return false;
}
return true;
})(a0) : c2667_1(a0) === "[object String]";
}
return r2;
};