@@ -190,12 +190,12 @@ function C.name(a, b, cfg)
190
190
return node_comparator_name_ignorecase_or_not (a , b , true , cfg )
191
191
end
192
192
193
- function C .modification_time (a , b )
193
+ function C .modification_time (a , b , cfg )
194
194
if not (a and b ) then
195
195
return true
196
196
end
197
197
198
- local early_return = folders_or_files_first (a , b )
198
+ local early_return = folders_or_files_first (a , b , cfg )
199
199
if early_return ~= nil then
200
200
return early_return
201
201
end
@@ -224,7 +224,7 @@ function C.suffix(a, b, cfg)
224
224
if early_return ~= nil then
225
225
return early_return
226
226
elseif a .nodes and b .nodes then
227
- return C .name (a , b )
227
+ return C .name (a , b , cfg )
228
228
end
229
229
230
230
-- dotfiles go second
@@ -233,7 +233,7 @@ function C.suffix(a, b, cfg)
233
233
elseif a .name :sub (1 , 1 ) ~= " ." and b .name :sub (1 , 1 ) == " ." then
234
234
return false
235
235
elseif a .name :sub (1 , 1 ) == " ." and b .name :sub (1 , 1 ) == " ." then
236
- return C .name (a , b )
236
+ return C .name (a , b , cfg )
237
237
end
238
238
239
239
-- unsuffixed go third
@@ -245,7 +245,7 @@ function C.suffix(a, b, cfg)
245
245
elseif a_suffix_ndx and not b_suffix_ndx then
246
246
return false
247
247
elseif not (a_suffix_ndx and b_suffix_ndx ) then
248
- return C .name (a , b )
248
+ return C .name (a , b , cfg )
249
249
end
250
250
251
251
-- finally, compare by suffixes
@@ -257,18 +257,18 @@ function C.suffix(a, b, cfg)
257
257
elseif not a_suffix and b_suffix then
258
258
return false
259
259
elseif a_suffix :lower () == b_suffix :lower () then
260
- return C .name (a , b )
260
+ return C .name (a , b , cfg )
261
261
end
262
262
263
263
return a_suffix :lower () < b_suffix :lower ()
264
264
end
265
265
266
- function C .extension (a , b )
266
+ function C .extension (a , b , cfg )
267
267
if not (a and b ) then
268
268
return true
269
269
end
270
270
271
- local early_return = folders_or_files_first (a , b )
271
+ local early_return = folders_or_files_first (a , b , cfg )
272
272
if early_return ~= nil then
273
273
return early_return
274
274
end
@@ -282,7 +282,7 @@ function C.extension(a, b)
282
282
local a_ext = (a .extension or " " ):lower ()
283
283
local b_ext = (b .extension or " " ):lower ()
284
284
if a_ext == b_ext then
285
- return C .name (a , b )
285
+ return C .name (a , b , cfg )
286
286
end
287
287
288
288
return a_ext < b_ext
@@ -307,7 +307,7 @@ function C.filetype(a, b, cfg)
307
307
308
308
-- same filetype or both nil, sort by name
309
309
if a_ft == b_ft then
310
- return C .name (a , b )
310
+ return C .name (a , b , cfg )
311
311
end
312
312
313
313
return a_ft < b_ft
0 commit comments