Skip to main content

mentions

Function mentions 

Source
pub fn mentions(
    text: &str,
    viewer: &str,
    in_team: &dyn Fn(&str) -> Option<bool>,
) -> bool
Expand description

Whether text asks for the viewer by name: @viewer, or @org/team for a team in_team says the viewer is in. A team nobody could check counts, as it does for a review request. An @ inside a word is an email address or code, and a login that runs on past the viewer’s is somebody else’s.