mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-11-17 01:37:40 +00:00
CAKE-356 | fixed _fetchEmojiFromUri method in the main.dart and fetchYatAddress method in the yat_record.dart
This commit is contained in:
parent
2cf827d946
commit
7fd4772121
2 changed files with 7 additions and 2 deletions
|
@ -228,11 +228,11 @@ class AppState extends State<App> with SingleTickerProviderStateMixin {
|
||||||
|
|
||||||
void _fetchEmojiFromUri(Uri uri, YatStore yatStore) {
|
void _fetchEmojiFromUri(Uri uri, YatStore yatStore) {
|
||||||
final queryParameters = uri.queryParameters;
|
final queryParameters = uri.queryParameters;
|
||||||
if (queryParameters == null || queryParameters.isEmpty) {
|
if (queryParameters?.isEmpty ?? true) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
final emoji = queryParameters['eid'];
|
final emoji = queryParameters['eid'];
|
||||||
if (emoji == null || emoji.isEmpty) {
|
if (emoji?.isEmpty ?? true) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
yatStore.emoji = emoji;
|
yatStore.emoji = emoji;
|
||||||
|
|
|
@ -20,5 +20,10 @@ Future<String> fetchYatAddress(String emojiId, String ticker) async {
|
||||||
}
|
}
|
||||||
|
|
||||||
final yatAddress = result.first['data'] as String;
|
final yatAddress = result.first['data'] as String;
|
||||||
|
|
||||||
|
if (yatAddress?.isEmpty ?? true) {
|
||||||
|
return '';
|
||||||
|
}
|
||||||
|
|
||||||
return yatAddress;
|
return yatAddress;
|
||||||
}
|
}
|
Loading…
Reference in a new issue