const constructure
This commit is contained in:
@@ -86,7 +86,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
);
|
||||
log("Error connecting to Bluetooth printer", name: _logName, error: e);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage(
|
||||
const PrinterFailure.dynamicErrorMessage(
|
||||
'Error connecting to Bluetooth printer',
|
||||
),
|
||||
);
|
||||
@@ -102,7 +102,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
} catch (e) {
|
||||
log("Error disconnecting Bluetooth printer", error: e, name: _logName);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage(
|
||||
const PrinterFailure.dynamicErrorMessage(
|
||||
'Error disconnecting Bluetooth printer',
|
||||
),
|
||||
);
|
||||
@@ -121,7 +121,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
} catch (e) {
|
||||
log("Error getting paired Bluetooth devices", name: _logName, error: e);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage(
|
||||
const PrinterFailure.dynamicErrorMessage(
|
||||
'Error getting paired Bluetooth devices',
|
||||
),
|
||||
);
|
||||
@@ -137,7 +137,9 @@ class PrinterRepository implements IPrinterRepository {
|
||||
} catch (e) {
|
||||
log("Error checking Bluetooth status", name: _logName, error: e);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage('Error checking Bluetooth status'),
|
||||
const PrinterFailure.dynamicErrorMessage(
|
||||
'Error checking Bluetooth status',
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -254,7 +256,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
],
|
||||
);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage(
|
||||
const PrinterFailure.dynamicErrorMessage(
|
||||
'Printer cannot connect to bluetooth, Please connect in printer setting!',
|
||||
),
|
||||
);
|
||||
@@ -306,7 +308,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
],
|
||||
);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage('Error printing struct'),
|
||||
const PrinterFailure.dynamicErrorMessage('Error printing struct'),
|
||||
);
|
||||
}
|
||||
});
|
||||
@@ -339,7 +341,7 @@ class PrinterRepository implements IPrinterRepository {
|
||||
information: ['Printer: ${printer.name}', 'IP: ${printer.address}'],
|
||||
);
|
||||
return left(
|
||||
PrinterFailure.dynamicErrorMessage('Error printing struct'),
|
||||
const PrinterFailure.dynamicErrorMessage('Error printing struct'),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user