mikemalinowski / qute

A Qt helper library extending Marcus Ottosson's Qt.py library
MIT License
12 stars 3 forks source link

Minor: Potentially unintentionally adding filepaths to QUTE_STYLE_LOCATIONS. #6

Closed ldunham1 closed 4 years ago

ldunham1 commented 4 years ago

https://github.com/mikemalinowski/qute/blob/3c5e1c34eba7153ba564910963f5c48c7abd1b4c/qute/constants.py#L24

os.path.isdir() will check if the path exists AND if its a directory. Depending on usage, it might be "safer" to use than os.path.exists().

mikemalinowski commented 4 years ago

Nice find - i had not even considered that. Switched to os.path.isdir as per your suggestion.