Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Add metadata logo path to SNS aggregator data #3301

Merged
merged 6 commits into from
Sep 12, 2023

Conversation

lmuntaner
Copy link
Contributor

@lmuntaner lmuntaner commented Sep 12, 2023

Motivation

The logo to the SNS Metadata needs to be hardcoded by the frontend following a specific pattern.

In this PR, I add the relative path of the logo so that the logic of where the logo lives lies only in the SNS aggregator canister.

Another reason is because the logo is optional. Therefore, this way it's easier to know whether the logo is present or not. Otherwise, we would need to try to fetch the asset and check it.

Changes

  • New field logo in SlowMetadata.
  • Change SlowMetadata::from to use UpstreamData to access the root canister id.

Tests

Tests are skipped.

Todos

  • Add entry to changelog (if necessary).

@lmuntaner lmuntaner requested a review from bitdivine September 12, 2023 05:50
@lmuntaner
Copy link
Contributor Author

@bitdivine please review

I added some questions / comments in the code changes.

Copy link
Member

@bitdivine bitdivine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

rs/sns_aggregator/src/types/slow.rs Outdated Show resolved Hide resolved
@lmuntaner lmuntaner marked this pull request as ready for review September 12, 2023 09:46
@lmuntaner lmuntaner force-pushed the fix_LM_default-sns-logo branch from 04ef221 to d86aa66 Compare September 12, 2023 09:47
@lmuntaner lmuntaner added this pull request to the merge queue Sep 12, 2023
Merged via the queue into main with commit 52cc6ed Sep 12, 2023
@lmuntaner lmuntaner deleted the fix_LM_default-sns-logo branch September 12, 2023 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants