chore(repo): add lints, update freezed, json_serializable
Signed-off-by: xsahil03x <[email protected]>
This commit is contained in:
@@ -12,7 +12,7 @@ part 'channel_dao.g.dart';
|
||||
class ChannelDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$ChannelDaoMixin {
|
||||
/// Creates a new channel dao instance
|
||||
ChannelDao(DriftChatDatabase db) : super(db);
|
||||
ChannelDao(super.db);
|
||||
|
||||
/// Get channel by cid
|
||||
Future<ChannelModel?> getChannelByCid(String cid) async =>
|
||||
|
||||
@@ -15,7 +15,7 @@ part 'channel_query_dao.g.dart';
|
||||
class ChannelQueryDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$ChannelQueryDaoMixin {
|
||||
/// Creates a new channel query dao instance
|
||||
ChannelQueryDao(DriftChatDatabase db) : super(db);
|
||||
ChannelQueryDao(super.db);
|
||||
|
||||
String _computeHash(Filter? filter) {
|
||||
if (filter == null) {
|
||||
|
||||
@@ -12,7 +12,7 @@ part 'connection_event_dao.g.dart';
|
||||
class ConnectionEventDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$ConnectionEventDaoMixin {
|
||||
/// Creates a new connection event dao instance
|
||||
ConnectionEventDao(DriftChatDatabase db) : super(db);
|
||||
ConnectionEventDao(super.db);
|
||||
|
||||
/// Get the latest stored connection event
|
||||
Future<Event?> get connectionEvent => select(connectionEvents)
|
||||
|
||||
@@ -14,7 +14,7 @@ part 'member_dao.g.dart';
|
||||
class MemberDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$MemberDaoMixin {
|
||||
/// Creates a new member dao instance
|
||||
MemberDao(DriftChatDatabase db) : super(db);
|
||||
MemberDao(super.db);
|
||||
|
||||
/// Get all members where [Members.channelCid] matches [cid]
|
||||
Future<List<Member>> getMembersByCid(String cid) async =>
|
||||
|
||||
@@ -12,7 +12,7 @@ part 'pinned_message_reaction_dao.g.dart';
|
||||
class PinnedMessageReactionDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$PinnedMessageReactionDaoMixin {
|
||||
/// Creates a new reaction dao instance
|
||||
PinnedMessageReactionDao(DriftChatDatabase db) : super(db);
|
||||
PinnedMessageReactionDao(super.db);
|
||||
|
||||
/// Returns all the reactions of a particular message by matching
|
||||
/// [Reactions.messageId] with [messageId]
|
||||
|
||||
@@ -12,7 +12,7 @@ part 'reaction_dao.g.dart';
|
||||
class ReactionDao extends DatabaseAccessor<DriftChatDatabase>
|
||||
with _$ReactionDaoMixin {
|
||||
/// Creates a new reaction dao instance
|
||||
ReactionDao(DriftChatDatabase db) : super(db);
|
||||
ReactionDao(super.db);
|
||||
|
||||
/// Returns all the reactions of a particular message by matching
|
||||
/// [Reactions.messageId] with [messageId]
|
||||
|
||||
@@ -11,7 +11,7 @@ part 'read_dao.g.dart';
|
||||
@DriftAccessor(tables: [Reads, Users])
|
||||
class ReadDao extends DatabaseAccessor<DriftChatDatabase> with _$ReadDaoMixin {
|
||||
/// Creates a new read dao instance
|
||||
ReadDao(DriftChatDatabase db) : super(db);
|
||||
ReadDao(super.db);
|
||||
|
||||
/// Get all reads where [Reads.channelCid] matches [cid]
|
||||
Future<List<Read>> getReadsByCid(String cid) async => (select(reads).join([
|
||||
|
||||
@@ -10,7 +10,7 @@ part 'user_dao.g.dart';
|
||||
@DriftAccessor(tables: [Users])
|
||||
class UserDao extends DatabaseAccessor<DriftChatDatabase> with _$UserDaoMixin {
|
||||
/// Creates a new user dao instance
|
||||
UserDao(DriftChatDatabase db) : super(db);
|
||||
UserDao(super.db);
|
||||
|
||||
/// Updates the users data with the new [userList] data
|
||||
Future<void> updateUsers(List<User> userList) => batch(
|
||||
|
||||
Reference in New Issue
Block a user