Skip to content

Commit

Permalink
Extract proposer url into a tag
Browse files Browse the repository at this point in the history
  • Loading branch information
danielsanchezq committed Jul 28, 2021
1 parent 620b99c commit 9e7e234
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/ideascale/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ pub struct IdeaScaleData {
}

pub type Rewards = HashMap<i32, i64>;
const PROPOSER_URL_TAG: &str = "website_github_repository__not_required_";

pub async fn fetch_all(fund: usize, api_token: String) -> Result<IdeaScaleData, Error> {
let funnels_task = tokio::spawn(fetch::get_funnels_data_for_fund(api_token.clone()));
Expand Down Expand Up @@ -174,7 +175,7 @@ pub fn build_proposals(
proposer_url: p
.custom_fields
.extra
.get("website_github_repository__not_required_")
.get(PROPOSER_URL_TAG)
.map(|c| c.as_str().unwrap())
.unwrap_or("")
.to_string(),
Expand Down

0 comments on commit 9e7e234

Please sign in to comment.