Browse Source

dynamite,nextcloud: Fix enum fromValue exceptions

pull/155/head
jld3103 2 years ago
parent
commit
4f6cc43cac
No known key found for this signature in database
GPG Key ID: 9062417B9E8EB7B3
  1. 2
      packages/dynamite/lib/src/openapi_builder.dart
  2. 8
      packages/nextcloud/lib/src/nextcloud.openapi.dart

2
packages/dynamite/lib/src/openapi_builder.dart

@ -1548,7 +1548,7 @@ TypeResult resolveType(
'return $identifier.${_toDartName(value.toString())};',
],
'default:',
'throw Exception(\'Can not parse UserStatusClearAtTime0 from "\$value"\');',
'throw Exception(\'Can not parse $identifier from "\$value"\');',
'}',
].join(),
),

8
packages/nextcloud/lib/src/nextcloud.openapi.dart

@ -3312,7 +3312,7 @@ enum NotesSettings_NoteMode {
case 'preview':
return NotesSettings_NoteMode.preview;
default:
throw Exception('Can not parse UserStatusClearAtTime0 from "$value"');
throw Exception('Can not parse NotesSettings_NoteMode from "$value"');
}
}
}
@ -3949,7 +3949,7 @@ enum UserStatusClearAt_Type {
case 'end-of':
return UserStatusClearAt_Type.endOf;
default:
throw Exception('Can not parse UserStatusClearAtTime0 from "$value"');
throw Exception('Can not parse UserStatusClearAt_Type from "$value"');
}
}
}
@ -3969,7 +3969,7 @@ enum UserStatusClearAt_Time0 {
case 'week':
return UserStatusClearAt_Time0.week;
default:
throw Exception('Can not parse UserStatusClearAtTime0 from "$value"');
throw Exception('Can not parse UserStatusClearAt_Time0 from "$value"');
}
}
}
@ -4101,7 +4101,7 @@ enum UserStatusType {
case 'invisible':
return UserStatusType.invisible;
default:
throw Exception('Can not parse UserStatusClearAtTime0 from "$value"');
throw Exception('Can not parse UserStatusType from "$value"');
}
}
}

Loading…
Cancel
Save