Changed all methods to accept database connection argument