class Habit { final int id; bool isComplete; String title; String? subtitle; //IconData icon; Habit({ required this.id, required this.isComplete, required this.title, this.subtitle, //required this.icon, }); factory Habit.fromSqfliteDatabase(Map map) => Habit( id: map['id']?.toInt(), isComplete: map['isComplete'] == 1, title: map['title'], subtitle: map['subtitle'] ?? '', //icon: const IconData(0xe800, fontFamily: 'MyCustomFont') //icon: map['icon'] ?? '', ); }