getRecentStickers method
Returns list of recently used Stickers from cache
Implementation
Future<List<RecentSticker>> getRecentStickers() async {
final prefs = await SharedPreferences.getInstance();
var sticker = prefs.getString('recent_stickers');
if (sticker == null) {
return [];
}
var json = jsonDecode(sticker) as List<dynamic>;
return json.map<RecentSticker>(RecentSticker.fromJson).toList();
}