pub async fn check_assignee(&self, assignee: impl AsRef<str>) -> Result<bool> {
        let route = format!(
            "repos/{owner}/{repo}/assignees/{assignee}",
            owner = self.owner,
            repo = self.repo,
            assignee = assignee.as_ref()
        );
        let response = self
            .crab
            ._get(self.crab.absolute_url(route)?, None::<&()>)
            .await?;
        let status = response.status();

        if status == 204 {
            Ok(true)
        } else if status == 404 {
            Ok(false)
        } else {
            Err(crate::map_github_error(response).await.unwrap_err())
        }
    }
/// Checks if a user has permission to be assigned to an issue in
/// the repository.
/// ```no_run
/// # async fn run() -> octocrab::Result<()> {
/// # let octocrab = octocrab::Octocrab::default();
/// assert!(octocrab.issues("owner", "repo").check_assignee("ferris").await?);
/// # Ok(())
/// # }
/// ```
Checks if a user has permission to be assigned to an issue in
the repository.
Checks if a user has permission to be assigned to an issue in the repository .
pub async fn check_assignee(&self, assignee: impl AsRef<str>) -> Result<bool> {
        let route = format!(
            "repos/{owner}/{repo}/assignees/{assignee}",
            owner = self.owner,
            repo = self.repo,
            assignee = assignee.as_ref()
        );
        let response = self
            .crab
            ._get(self.crab.absolute_url(route)?, None::<&()>)
            .await?;
        let status = response.status();
        if status == 204 {
            Ok(true)
        } else if status == 404 {
            Ok(false)
        } else {
            Err(crate::map_github_error(response).await.unwrap_err())
        }
    }
pub async fn check_assignee ( & self , assignee : impl AsRef < str > ) -> Result < bool > { let route = format ! ( " " owner self owner repo self repo assignee assignee as_ref ( ) ) ; let response = self . crab . _get ( self . crab . absolute_url ( route ) ? , None :: < & ( ) > ) . await ? ; let status = response . status ( ) ; if status == 204 { Ok ( true ) } else if status == 404 { Ok ( false ) } else { Err ( crate :: map_github_error ( response ) . await . unwrap_err ( ) ) } }
Checks if a user has permission to be assigned to an issue in
the repository.
Checks if a user has permission to be assigned to an issue in the repository .
&self
assignee
impl AsRef<str>
&self
assignee
impl AsRef<str>
async fn run() -> octocrab::result<()> {
None
let octocrab = octocrab::octocrab::default();
None
ok(())
None
}
None