Skip to content

Commit

Permalink
app: fixes pob open url for user pastes
Browse files Browse the repository at this point in the history
  • Loading branch information
Dav1dde committed Nov 20, 2024
1 parent 29101f8 commit eaa990b
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions shared/src/id.rs
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ impl UserPasteId {
}

pub fn to_pob_load_url(&self) -> UrlSafe<'static> {
// TODO: maybe get rid of this format?
UrlSafe::SLASH
.join("pob")
.join(UrlSafe::new(&self.user).push(":").push(&*self.id))
Expand All @@ -140,12 +139,8 @@ impl UserPasteId {
}

pub fn to_pob_open_url(&self) -> UrlSafe<'static> {
// ("pob").join("u").join(&*self.user).join(&*self.id)
// format!("pob://pobbin/{}:{}", self.user, self.id)
UrlSafe::from_static("pob://pobbin/")
.join(&*self.user)
.push(":")
.join(&*self.id)
.join(UrlSafe::new(&self.user).push(":").push(&*self.id))
}
}

Expand Down

0 comments on commit eaa990b

Please sign in to comment.