mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-07 23:17:32 -06:00
Simplify detection of url-encoded filepatch
This commit is contained in:
parent
65ada30c9c
commit
846c55a99d
1 changed files with 2 additions and 2 deletions
|
@ -127,8 +127,8 @@ class USBPrinterOutputDevice(PrinterOutputDevice):
|
||||||
|
|
||||||
@pyqtSlot(str)
|
@pyqtSlot(str)
|
||||||
def updateFirmware(self, file):
|
def updateFirmware(self, file):
|
||||||
# the file path could be qurl encoded.
|
# the file path could be url-encoded.
|
||||||
if file[:7] == "file://":
|
if file.startswith("file://"):
|
||||||
self._firmware_location = QUrl(file).toLocalFile()
|
self._firmware_location = QUrl(file).toLocalFile()
|
||||||
else:
|
else:
|
||||||
self._firmware_location = file
|
self._firmware_location = file
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue