Show instance sponsors if OC is set as donation url
What does this PR do?
This was requested by @piuvas on discord after the OC sponsor fetching was added.
All this does is expand the sponsors endpoint to add an instance
boolean which is set to true on the instance information page.
It will check if a cached version exists first like the normal sponsor one does for the sharkey page.
If not then it checks the donationUrl is set and if it points to opencollective followed by it fetching all backers.
It then sorts by isActive and if Tier is set on user (otherwise it will show all backers) and then returns and caches it.
Contribution Guidelines By submitting this merge request, you agree to follow our Contribution Guidelines
-
I agree to follow this project's Contribution Guidelines -
I have made sure to test this pull request
Merge request reports
Activity
added 3 commits
-
dcd6eee6...b151d193 - 2 commits from branch
develop
- 0897458c - Merge branch 'develop' into upd/instancesponsor
-
dcd6eee6...b151d193 - 2 commits from branch
- Resolved by Marie
- Resolved by dakkar
- Resolved by Marie
added 4 commits
-
0897458c...72baaaab - 2 commits from branch
develop
- e2010caa - Merge branch 'develop' into upd/instancesponsor
- 34cbf552 - upd: apply suggestion
-
0897458c...72baaaab - 2 commits from branch
requested review from @dakkar
- Resolved by Marie
- Resolved by Marie
added 1 commit
- 6b459be1 - upd: move totalSponsors and donationUrl check
- Resolved by Marie
added 1 commit
- f08ef28d - upd: fix broken returns and change if statement
- Resolved by Marie
- Resolved by Marie