]> Untitled Git - lemmy.git/blobdiff - crates/db_views_actor/src/community_view.rs
Diesel 2.0.0 upgrade (#2452)
[lemmy.git] / crates / db_views_actor / src / community_view.rs
index 0701ab430592c2e799f965b71218dfa84a5ba935..5a65b887b92a4e38bf3a13f5bf0245a1fc4e492e 100644 (file)
@@ -25,7 +25,7 @@ type CommunityViewTuple = (
 
 impl CommunityView {
   pub fn read(
-    conn: &PgConnection,
+    conn: &mut PgConnection,
     community_id: CommunityId,
     my_person_id: Option<PersonId>,
   ) -> Result<Self, Error> {
@@ -66,7 +66,7 @@ impl CommunityView {
   }
 
   pub fn is_mod_or_admin(
-    conn: &PgConnection,
+    conn: &mut PgConnection,
     person_id: PersonId,
     community_id: CommunityId,
   ) -> bool {
@@ -97,7 +97,7 @@ impl CommunityView {
 #[builder(field_defaults(default))]
 pub struct CommunityQuery<'a> {
   #[builder(!default)]
-  conn: &'a PgConnection,
+  conn: &'a mut PgConnection,
   listing_type: Option<ListingType>,
   sort: Option<SortType>,
   local_user: Option<&'a LocalUser>,