statistic_tracker
Version:
A Statistic Tracker for Apex Legends, Cs:Go, Fortnite and Overwatch
16 lines (15 loc) • 547 B
JavaScript
;
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const node_fetch_1 = __importDefault(require("node-fetch"));
exports.get = (url, options) => {
let data = null;
let error = null;
node_fetch_1.default(url, options)
.then(res => res.json())
.then(json => data = json)
.catch(error => error = error);
return { data, error };
};