(
&self,
plugin_id: u64,
image: CreateUpdatePluginImage,
)
| 187 | } |
| 188 | |
| 189 | async fn inner_upsert_plugin_image( |
| 190 | &self, |
| 191 | plugin_id: u64, |
| 192 | image: CreateUpdatePluginImage, |
| 193 | ) -> ConfigStoreResult<()> { |
| 194 | sqlx::query!( |
| 195 | "INSERT INTO plugin_images (plugin_id, image_id, created_at, description, position, \ |
| 196 | kind) |
| 197 | VALUES ($1, $2, now(), $3, $4, $5) |
| 198 | ON CONFLICT (plugin_id, image_id) DO UPDATE SET |
| 199 | description = $3;", |
| 200 | plugin_id as i64, |
| 201 | image.image_id, |
| 202 | image.description, |
| 203 | image.position, |
| 204 | i32::from(image.kind), |
| 205 | ) |
| 206 | .execute(&self.pool) |
| 207 | .await?; |
| 208 | |
| 209 | Ok(()) |
| 210 | } |
| 211 | |
| 212 | pub async fn get_user_by_stripe_customer_id( |
| 213 | &self, |
no test coverage detected