UNPKG

epicwar

Version:
17 lines (16 loc) 478 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getMapImage = void 0; function getMapImage(cells) { for (const cell of cells) { const imgs = cell.getElementsByTagName('img'); for (const img of imgs) { const { src } = img; if (src.startsWith('//www.epicwar.com/assets/p')) { return `https:${src}`; } } } return null; } exports.getMapImage = getMapImage;