diff options
author | monsta <[email protected]> | 2019-01-10 11:10:10 +0300 |
---|---|---|
committer | monsta <[email protected]> | 2019-01-10 11:10:10 +0300 |
commit | 55e4f9b9e8b8ece3c8a25d108dde5ebdf9aef397 (patch) | |
tree | ec0583392c421d5b328e9d5a56e6b8aee3e4ff35 /caja-dropbox.in | |
parent | 343a3fb58e0584a997a528ce766b429755be4f3b (diff) | |
download | caja-dropbox-55e4f9b9e8b8ece3c8a25d108dde5ebdf9aef397.tar.bz2 caja-dropbox-55e4f9b9e8b8ece3c8a25d108dde5ebdf9aef397.tar.xz |
fix UnicodeWarning when exclude command is used with non-latin args
like this:
$ caja-dropbox exclude тест
$ caja-dropbox exclude тест тест2
it's not the correct command usage, but we don't need a warning anyway
Diffstat (limited to 'caja-dropbox.in')
-rwxr-xr-x | caja-dropbox.in | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/caja-dropbox.in b/caja-dropbox.in index c96e7e3..cfcf4f5 100755 --- a/caja-dropbox.in +++ b/caja-dropbox.in @@ -1384,10 +1384,10 @@ Any specified path must be within Dropbox. console_print(u"Dropbox daemon stopped.") except DropboxCommand.CouldntConnectError, e: console_print(u"Dropbox isn't running!") - elif len(args) == 1 and args[0] == u"list": + elif len(args) == 1 and args[0].decode(sys.getfilesystemencoding()) == u"list": exclude([]) elif len(args) >= 2: - sub_command = args[0] + sub_command = args[0].decode(sys.getfilesystemencoding()) paths = args[1:] absolute_paths = [unicode_abspath(path.decode(sys.getfilesystemencoding())) for path in paths] if sub_command == u"add": |