Skip to main content

update

Function update 

Source
pub async fn update(
    pool: &Pool,
    taxonomy_id: i64,
    id: i64,
    new: NewCategory,
) -> Result<Category, CategoryError>
Expand description

Update a category’s base fields in place (name/slug/description/media). Re-checks slug uniqueness among siblings (excluding self). Does not re-parent — use move_to for that.

§Errors

CategoryError::DuplicateSlug, NotFound, or DB failure.