aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2021-07-05 15:29:43 -0700
committerFuwn <[email protected]>2021-07-05 15:29:43 -0700
commitb901141de914539c2a01f3b8a4f224762dcbb009 (patch)
treebabfb38604f416797357181aacbb2996c35ba0dd
parentrefactor(whirl_api): route scoping (diff)
downloadwhirl-b901141de914539c2a01f3b8a4f224762dcbb009.tar.xz
whirl-b901141de914539c2a01f3b8a4f224762dcbb009.zip
refactor(whirl_api): /api/v1/worlds/info default to empty string intead of "null"
When defaulting to "null", the API request would query for a user with the username "null", by querying for an empty string, no possible false information is provided.
-rw-r--r--crates/whirl_api/src/routes/worlds/info/mod.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/whirl_api/src/routes/worlds/info/mod.rs b/crates/whirl_api/src/routes/worlds/info/mod.rs
index eedac82..6ea1453 100644
--- a/crates/whirl_api/src/routes/worlds/info/mod.rs
+++ b/crates/whirl_api/src/routes/worlds/info/mod.rs
@@ -16,7 +16,7 @@ pub fn info(req: HttpRequest) -> HttpResponse {
"http://www-dynamic.us.worlds.net/cgi-bin/profile.pl?{}",
qstring::QString::from(req.query_string())
.get("username")
- .unwrap_or("null"),
+ .unwrap_or(""),
))
.unwrap();