Skip to content

Commit

Permalink
Extractingdata variable can be private
Browse files Browse the repository at this point in the history
  • Loading branch information
g123k committed Jun 15, 2024
1 parent fb2d1ee commit a685edd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/smooth_app/lib/pages/product/edit_ocr_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class _EditOcrPageState extends State<EditOcrPage> with UpToDateMixin {
late final MultilingualHelper _multilingualHelper;

OcrHelper get _helper => widget.helper;
bool extractingData = false;
bool _extractingData = false;

@override
void initState() {
Expand All @@ -65,7 +65,7 @@ class _EditOcrPageState extends State<EditOcrPage> with UpToDateMixin {
///
/// When done, populates the related page field.
Future<void> _extractData() async {
setState(() => extractingData = true);
setState(() => _extractingData = true);

try {
final String? extractedText = await _helper.getExtractedText(
Expand All @@ -76,7 +76,7 @@ class _EditOcrPageState extends State<EditOcrPage> with UpToDateMixin {
return;
}

setState(() => extractingData = false);
setState(() => _extractingData = false);

if (extractedText == null || extractedText.isEmpty) {
await LoadingDialog.error(
Expand Down Expand Up @@ -377,7 +377,7 @@ class _EditOcrPageState extends State<EditOcrPage> with UpToDateMixin {
}

OcrState _extractState(TransientFile transientFile) {
if (extractingData) {
if (_extractingData) {
return OcrState.EXTRACTING_DATA;
} else if (transientFile.isServerImage()) {
return OcrState.IMAGE_LOADED;
Expand Down

0 comments on commit a685edd

Please sign in to comment.