From 2ef08aff13be0e71cae30376d32190c3feecd0e0 Mon Sep 17 00:00:00 2001 From: valkyrie_pilot Date: Sun, 28 Apr 2024 12:22:22 -0600 Subject: [PATCH] Trim IPs --- Cargo.lock | 8 ++++---- assets/main.js | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 1fbdf67..9a91241 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -654,18 +654,18 @@ checksum = "80af6f9131f277a45a3fba6ce8e2258037bb0477a67e610d3c1fe046ab31de47" [[package]] name = "serde" -version = "1.0.198" +version = "1.0.199" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9846a40c979031340571da2545a4e5b7c4163bdae79b301d5f86d03979451fcc" +checksum = "0c9f6e76df036c77cd94996771fb40db98187f096dd0b9af39c6c6e452ba966a" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.198" +version = "1.0.199" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e88edab869b01783ba905e7d0153f9fc1a6505a96e4ad3018011eedb838566d9" +checksum = "11bd257a6541e141e42ca6d24ae26f7714887b47e89aa739099104c7e4d3b7fc" dependencies = [ "proc-macro2", "quote", diff --git a/assets/main.js b/assets/main.js index 83bee97..e2a06c7 100644 --- a/assets/main.js +++ b/assets/main.js @@ -10,7 +10,7 @@ if (ip4txt.hidden) { fetch(v4_endpoint) .then((req) => req.text()) .then((resp) => { - ip4.innerText = resp; + ip4.innerText = resp.trim(); ip4txt.hidden = false; document.getElementById("title").innerText = `Your IP is ${resp}`; }) @@ -22,7 +22,7 @@ if (ip6txt.hidden) { fetch(v6_endpoint) .then((req) => req.text()) .then((resp) => { - ip6.innerText = resp; + ip6.innerText = resp.trim(); ip6txt.hidden = false; }) .catch((failed) => {