pub async fn poll_exists(pool: &DBPool, poll_id: i32) -> Result<bool> {
        let res = generic_service_err!(
            sqlx::query_file_as!(Poll, "sql/poll/get_poll.sql", poll_id)
            .fetch_all(pool).await,
            "Failed to check if poll exists");

        Ok(res.len() == 1)
    }
/// Returns whether or not a poll exists
/// 
/// # Arguments
/// 
/// * `pool` - The database pool
/// * `poll_id` - The ID of the poll
Returns whether or not a poll exists
Returns whether or not a poll exists
pub async fn poll_exists(pool: &DBPool, poll_id: i32) -> Result<bool> {
        let res = generic_service_err!(
            sqlx::query_file_as!(Poll, "sql/poll/get_poll.sql", poll_id)
            .fetch_all(pool).await,
            "Failed to check if poll exists");
        Ok(res.len() == 1)
    }
pub async fn poll_exists ( pool : & DBPool , poll_id : i32 ) -> Result < bool > { let res = generic_service_err ! ( sqlx query_file_as ( Poll " " poll_id ) fetch_all ( pool ) await " " ) ; Ok ( res . len ( ) == 1 ) }
Returns whether or not a poll exists
Returns whether or not a poll exists
pool
&DBPool
poll_id
i32
pool
&DBPool
poll_id
i32