You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-11-29 22:48:10 +02:00
Better handling of network errors
This commit is contained in:
@@ -72,7 +72,7 @@ class NoteItemComponent extends Component {
|
||||
const listItemStyle = !!Number(note.is_todo) && checkboxChecked ? styles.listItemFadded : styles.listItem;
|
||||
|
||||
return (
|
||||
<TouchableHighlight style={{borderWidth:1, borderColor:'red'}} onPress={() => this.onPress()} underlayColor="#0066FF">
|
||||
<TouchableHighlight onPress={() => this.onPress()} underlayColor="#0066FF">
|
||||
<View style={ listItemStyle }>
|
||||
<Checkbox
|
||||
style={checkboxStyle}
|
||||
|
||||
@@ -112,7 +112,14 @@ class SideMenuContentComponent extends Component {
|
||||
return;
|
||||
}
|
||||
|
||||
const sync = await reg.synchronizer(Setting.value('sync.target'))
|
||||
let sync = null;
|
||||
try {
|
||||
sync = await reg.synchronizer(Setting.value('sync.target'))
|
||||
} catch (error) {
|
||||
reg.logger().info('Could not acquire synchroniser:');
|
||||
reg.logger().info(error);
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.props.syncStarted) {
|
||||
sync.cancel();
|
||||
|
||||
Reference in New Issue
Block a user