Fix url router

This commit is contained in:
Thomas Ricouard 2024-01-01 09:23:06 +01:00
parent b4757621f2
commit 7222d530dd

View file

@ -140,7 +140,9 @@ public enum SheetDestination: Identifiable {
{
navigate(to: .hashTag(tag: tag, account: nil))
return .handled
} else if url.lastPathComponent.first == "@", let host = url.host {
} else if url.lastPathComponent.first == "@",
let host = url.host,
!host.hasPrefix("www") {
let acct = "\(url.lastPathComponent)@\(host)"
Task {
await navigateToAccountFrom(acct: acct, url: url)