Skip to content

Commit

Permalink
make it not crash immediately on termux.
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkra230 authored Nov 12, 2023
1 parent abde094 commit afa7385
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@ const dns2 = require("dns2");
const dns = new dns2();
const { Packet } = dns2;
const dnsServer = dns2.createServer({ udp: true });
const localIp = require("local-ipv4-address")();
let localIp
try {
localIp = require("local-ipv4-address")();
} catch {
localIp = new Promise((res)=>{res("failed")})
}
const prompt = require("prompt-sync")();
const keys = require("./custom/licensoft/index");
const app = express();
Expand Down

0 comments on commit afa7385

Please sign in to comment.