mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-09 22:57:21 +00:00
check type isNotEmpty
This commit is contained in:
@ -60,7 +60,7 @@ class _RoleDropdownState extends State<RoleDropdown> {
|
||||
return DropdownMenuItem<String>(
|
||||
value: role.uuid,
|
||||
child: Text(
|
||||
' ${role.type[0].toUpperCase()}${role.type.substring(1)}',
|
||||
' ${role.type.isNotEmpty ? role.type[0].toUpperCase() : ''}${role.type.substring(1)}',
|
||||
),
|
||||
);
|
||||
}).toList(),
|
||||
|
Reference in New Issue
Block a user