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

Function get_vendor

chirpstack/src/storage/device_profile.rs:622–629  ·  view source on GitHub ↗
(id: Uuid)

Source from the content-addressed store, hash-verified

620}
621
622pub async fn get_vendor(id: Uuid) -> Result<Vendor, Error> {
623 let v = device_profile_vendor::table
624 .find(&fields::Uuid::from(id))
625 .first(&mut get_async_db_conn().await?)
626 .await
627 .map_err(|e| Error::from_diesel(e, id.to_string()))?;
628 Ok(v)
629}
630
631pub async fn delete_vendor(id: uuid::Uuid) -> Result<(), Error> {
632 let ra = diesel::delete(device_profile_vendor::table.find(&fields::Uuid::from(id)))

Callers 2

test_device_profileFunction · 0.85
get_vendorMethod · 0.85

Calls 2

to_stringMethod · 0.80
get_async_db_connFunction · 0.70

Tested by 1

test_device_profileFunction · 0.68