File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 4
4
import sublime
5
5
import sublime_plugin
6
6
import subprocess
7
+ import json
7
8
from os import path , name
8
9
9
10
__file__ = path .normpath (path .abspath (__file__ ))
@@ -36,9 +37,8 @@ def run(self, edit):
36
37
37
38
self .sortorder = False
38
39
self .order_settings = sublime .load_settings ('CSScomb.sublime-settings' )
39
- if self .order_settings .has ('custom_sort_order' ) and self .order_settings .get ('custom_sort_order' ) == True :
40
- self .sortorder = self .order_settings .get ('sort_order' )
41
- self .sortorder = '["' + '","' .join (self .sortorder ) + '"]'
40
+ if self .order_settings .has ('custom_sort_order' ) and self .order_settings .get ('custom_sort_order' ) is True :
41
+ self .sortorder = json .dumps (self .order_settings .get ('sort_order' ))
42
42
sublime .status_message ('Sorting with custom sort order...' )
43
43
else :
44
44
self .sortorder = ''
@@ -79,7 +79,7 @@ def get_selections(self):
79
79
# check if the user has any actual selections
80
80
has_selections = False
81
81
for region in selections :
82
- if region .empty () == False :
82
+ if region .empty () is False :
83
83
has_selections = True
84
84
85
85
# if not, add the entire file as a selection
You can’t perform that action at this time.
0 commit comments