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

875 generer des liens de partage avec parametre via #1061

Merged

Conversation

NicolasBuquet
Copy link
Contributor

Fix #875

Testé sur :

  • salon avec alias existant (pas de changement)
  • salon sans accès par lien activé (le lien reste non calculé ni affiché)
  • forum sans alias (le lien est calculé à partir du roomId et des homeServers des membres pour les paramètres 'via')

Simulator Screenshot - iPhone 15 - 2024-06-17 at 18 25 08

Copy link
Contributor

@yostyle yostyle left a comment

Choose a reason for hiding this comment

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

LGTM. Just one suggestion


NSString *urlPrefix = BuildSettings.clientPermalinkBaseUrl;
NSString *viaParameters = [NSString stringWithFormat:@"?via=%@", [memberHomeservers.allObjects componentsJoinedByString:@"&via="]];
NSString *permalinkToRoom = [NSString stringWithFormat:@"%@/#/room/%@%@", urlPrefix, roomId, viaParameters];
Copy link
Contributor

Choose a reason for hiding this comment

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

You should update permalinkToRoom in Tools.m from Tchap > Utils and using it. What do you think about that ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I thought about it be didn't make it because the modification here, building via parameters does a lot more stuff than permalinkToRoom. It will denaturate permalinkToRoom.
That's why I prefered to define a standalone permalinkToRoomWithoutAliasFromRoomState.

@NicolasBuquet NicolasBuquet merged commit b50d1e6 into develop Jun 24, 2024
3 of 7 checks passed
@NicolasBuquet NicolasBuquet deleted the 875-generer-des-liens-de-partage-avec-parametre-via branch June 24, 2024 14:50
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.

Impossible de rejoindre un forum d'un autre homeserver depuis un lien généré sur mobile
2 participants