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

Fix link char count (IOS-285) #1336

Merged
merged 3 commits into from
Jul 31, 2024
Merged

Fix link char count (IOS-285) #1336

merged 3 commits into from
Jul 31, 2024

Conversation

kimar
Copy link
Contributor

@kimar kimar commented Jul 31, 2024

This PR fixes the link char count which should be static (by default 23 chars per link) rather than the length of the link itself.

@kimar kimar self-assigned this Jul 31, 2024
let charactersReservedPerURL = authContext.mastodonAuthenticationBox
.authentication
.instanceConfiguration?
.charactersReservedPerURL ?? MastodonAuthentication.fallbackCharactersReservedPerURL
Copy link
Member

Choose a reason for hiding this comment

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

Do you need the fallback here, if its already checked in MastodonAuthentication?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Unfortunately we do because instanceConfiguration is optional and might not (yet) exist at this point.

@kimar kimar merged commit 8543142 into develop Jul 31, 2024
2 checks passed
@kimar kimar deleted the ios-285-link-count branch July 31, 2024 10:56
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.

2 participants