fix: explicitly set scheme for local file in -I argument
Otherwise isLocalFile() will return false for local files without the file:// thingy. Signed-off-by: flow <flowlnlnln@gmail.com>
This commit is contained in:
		@@ -1817,6 +1817,10 @@ void MainWindow::droppedURLs(QList<QUrl> urls)
 | 
			
		||||
{
 | 
			
		||||
    // NOTE: This loop only processes one dropped file!
 | 
			
		||||
    for (auto& url : urls) {
 | 
			
		||||
        // The isLocalFile() check below doesn't work as intended without an explicit scheme.
 | 
			
		||||
        if (url.scheme().isEmpty())
 | 
			
		||||
            url.setScheme("file");
 | 
			
		||||
 | 
			
		||||
        if (!url.isLocalFile()) {  // probably instance/modpack
 | 
			
		||||
            addInstance(url.toString());
 | 
			
		||||
            break;
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user