Skip to main content

sofie_model/
gating.rs

1use crate::{App, KnownArea};
2
3impl App {
4    #[must_use]
5    pub fn has_feature_flags(&self) -> bool {
6        self.modules
7            .iter()
8            .any(|module| !module.code.features.declarations.is_empty())
9    }
10
11    #[must_use]
12    pub fn has_permitted_areas(&self) -> bool {
13        self.areas().iter().any(KnownArea::is_permitted)
14    }
15}