repo_toggle_for

Function repo_toggle_for 

Source
pub fn repo_toggle_for(repo: &str, app: &AppState) -> bool
Expand description

What: Determine whether results from a repository should be visible under current toggles.

Inputs:

  • repo: Name of the repository associated with a package result.
  • app: Application state providing the filter toggles for official repos.

Output:

  • true when the repository passes the active filters; otherwise false.

Details:

  • Normalizes repository names and applies special-handling for EOS/CachyOS/Artix classification helpers.
  • Unknown repositories are only allowed when every official filter is enabled simultaneously.