MCPcopy Create free account
hub / github.com/chirpstack/chirpstack / delete

Function delete

chirpstack/src/storage/multicast.rs:184–193  ·  view source on GitHub ↗
(id: &Uuid)

Source from the content-addressed store, hash-verified

182}
183
184pub async fn delete(id: &Uuid) -> Result<(), Error> {
185 let ra = diesel::delete(multicast_group::dsl::multicast_group.find(&fields::Uuid::from(id)))
186 .execute(&mut get_async_db_conn().await?)
187 .await?;
188 if ra == 0 {
189 return Err(Error::NotFound(id.to_string()));
190 }
191 info!(id = %id, "Multicast-group deleted");
192 Ok(())
193}
194
195pub async fn get_count(filters: &Filters) -> Result<i64, Error> {
196 let mut q = multicast_group::table

Callers 5

remove_deviceFunction · 0.70
remove_gatewayFunction · 0.70
delete_queue_itemFunction · 0.70
flush_queueFunction · 0.70
test_multicast_groupFunction · 0.70

Calls 2

to_stringMethod · 0.80
get_async_db_connFunction · 0.70

Tested by 1

test_multicast_groupFunction · 0.56