From 925e57fe599931cb41b5a6f8a8ed4085e7a12987 Mon Sep 17 00:00:00 2001 From: Jaakko Keränen Date: Wed, 24 Feb 2021 05:13:39 +0200 Subject: Cleanup --- src/ui/documentwidget.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'src') diff --git a/src/ui/documentwidget.c b/src/ui/documentwidget.c index 7bf0beca..0722976a 100644 --- a/src/ui/documentwidget.c +++ b/src/ui/documentwidget.c @@ -1980,16 +1980,7 @@ static iBool handleCommand_DocumentWidget_(iDocumentWidget *d, const char *cmd) return iTrue; } else if (equal_Command(cmd, "navigate.root") && document_App() == d) { - iUrl parts; - init_Url(&parts, d->mod.url); - const char *rootEnd = parts.path.start; - const iRangecc user = urlUser_String(d->mod.url); - if (!isEmpty_Range(&user)) { - rootEnd = user.end; - } - postCommandf_App( - "open url:%s/", - cstr_Rangecc((iRangecc){ constBegin_String(d->mod.url), rootEnd })); + postCommandf_App("open url:%s/", cstr_Rangecc(urlRoot_String(d->mod.url))); return iTrue; } else if (equalWidget_Command(cmd, w, "scroll.moved")) { -- cgit v1.2.3