Skip to content

Commit

Permalink
Fix --chooser
Browse files Browse the repository at this point in the history
  • Loading branch information
probonopd committed Aug 28, 2023
1 parent 1c667f3 commit 0bf0622
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/launcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -620,7 +620,7 @@ int Launcher::open(QStringList args)
removalCandidates = {}; // For applications that possibly don't exist on disk anymore

// NOTE: magnet:?xt=urn:btih:... URLs do not contain ":/"
if ((!QFileInfo::exists(firstArg)) && (!firstArg.contains(":/"))
if (!showChooserRequested && (!QFileInfo::exists(firstArg)) && (!firstArg.contains(":/"))
&& (!firstArg.contains(":?"))) {
if (QFileInfo(firstArg).isSymLink()) {
// Broken symlink
Expand All @@ -640,7 +640,7 @@ int Launcher::open(QStringList args)
}

// Check whether the file to be opened is an ELF executable or a script missing the executable bit
if(Executable::hasShebangOrIsElf(firstArg)) {
if(!showChooserRequested && Executable::hasShebangOrIsElf(firstArg)) {
QStringList executableAndArgs;
QFileInfo info = QFileInfo(firstArg);
if(info.isExecutable()) {
Expand Down

0 comments on commit 0bf0622

Please sign in to comment.