diff --git a/app/lib/bloc/search.dart b/app/lib/bloc/search.dart index b2375167..9ea687c3 100644 --- a/app/lib/bloc/search.dart +++ b/app/lib/bloc/search.dart @@ -62,7 +62,7 @@ abstract class SearchBlocState { } class SearchBlocInit extends SearchBlocState { - SearchBlocInit() : super(null, const SearchCriteria("", []), const []); + SearchBlocInit() : super(null, SearchCriteria("", []), const []); } class SearchBlocLoading extends SearchBlocState { diff --git a/app/lib/entity/search.dart b/app/lib/entity/search.dart index 8ed66967..b86acc10 100644 --- a/app/lib/entity/search.dart +++ b/app/lib/entity/search.dart @@ -5,7 +5,7 @@ import 'package:nc_photos/entity/sqlite_table_extension.dart' as sql; import 'package:nc_photos/iterable_extension.dart'; class SearchCriteria { - const SearchCriteria(this.input, this.filters); + SearchCriteria(String input, this.filters) : input = input.trim(); SearchCriteria copyWith({ String? input,