@eht16 commented on this pull request.
>
- if (g_utf8_strchr(needles, -1, 'f') != NULL && strstr(haystack->str,
"%f")) {
- g_string_append(errormsg, " %%f");
+ /* %p is the project base path, if any */
+ if (placeholder == 'p' && app->project)
+ r = project_get_base_path();
+ else if (! doc || ! doc->file_name)
+ {
+ ui_set_statusbar(FALSE, _("failed to substitute %%%c: document
has no path"), placeholder);
+ /* TODO: Shouldn't we rather return an empty string for known
placeholders?
Returning an empty string should be ok, I think.
This case should be rather hard to reach at all.
--
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/4318#pullrequestreview-2907319679
You are receiving this because you are subscribed to this thread.
Message ID: <geany/geany/pull/4318/review/[email protected]>