From 22340cb88e056211cd2e08036e7a1982e37c391b Mon Sep 17 00:00:00 2001 From: fiaxh Date: Sat, 24 Nov 2018 21:00:44 +0100 Subject: Always use Account.hash(equals)_func for HashMap+ArrayList --- libdino/src/service/database.vala | 2 +- libdino/src/service/module_manager.vala | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'libdino') diff --git a/libdino/src/service/database.vala b/libdino/src/service/database.vala index e5ddd0f2..025a97fa 100644 --- a/libdino/src/service/database.vala +++ b/libdino/src/service/database.vala @@ -268,7 +268,7 @@ public class Database : Qlite.Database { } public ArrayList get_accounts() { - ArrayList ret = new ArrayList(); + ArrayList ret = new ArrayList(Account.equals_func); foreach(Row row in account.select()) { Account account = new Account.from_row(this, row); ret.add(account); diff --git a/libdino/src/service/module_manager.vala b/libdino/src/service/module_manager.vala index d16dc935..b9197f90 100644 --- a/libdino/src/service/module_manager.vala +++ b/libdino/src/service/module_manager.vala @@ -6,7 +6,7 @@ using Xmpp; namespace Dino { public class ModuleManager { - private HashMap> module_map = new HashMap>(); + private HashMap> module_map = new HashMap>(Account.hash_func, Account.equals_func); private EntityCapabilitiesStorage entity_capabilities_storage; -- cgit v1.2.3-70-g09d2