mirror of
https://github.com/immich-app/immich
synced 2025-11-14 17:36:12 +00:00
chore(mobile): lint (#16182)
* lint - convert path to lowercase for finding index * update dcm lint rules --------- Co-authored-by: shenlong-tanwen <139912620+shalong-tanwen@users.noreply.github.com>
This commit is contained in:
parent
f1b98d5f45
commit
70d08a2b2a
2 changed files with 59 additions and 28 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import 'package:analyzer/error/listener.dart';
|
||||
import 'package:analyzer/error/error.dart' show ErrorSeverity;
|
||||
import 'package:analyzer/error/listener.dart';
|
||||
import 'package:custom_lint_builder/custom_lint_builder.dart';
|
||||
// ignore: depend_on_referenced_packages
|
||||
import 'package:glob/glob.dart';
|
||||
|
|
@ -65,7 +65,8 @@ class ImportRule extends DartLintRule {
|
|||
) {
|
||||
if (_rootOffset == -1) {
|
||||
const project = "/immich/mobile/";
|
||||
_rootOffset = resolver.path.indexOf(project) + project.length;
|
||||
_rootOffset =
|
||||
resolver.path.toLowerCase().indexOf(project) + project.length;
|
||||
}
|
||||
final path = resolver.path.substring(_rootOffset);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue