mirror of
https://github.com/zjs81/meshcore-open.git
synced 2026-04-20 22:13:48 +00:00
Merge pull request #59 from 446564/community-#-names
add community to hashtag channel name
This commit is contained in:
commit
488a286701
1 changed files with 5 additions and 4 deletions
|
|
@ -1046,10 +1046,11 @@ class _ChannelsScreenState extends State<ChannelsScreen>
|
|||
if (hashtag.startsWith('#')) {
|
||||
hashtag = hashtag.substring(1);
|
||||
}
|
||||
final channelName = '#$hashtag';
|
||||
|
||||
final String channelName;
|
||||
|
||||
final Uint8List psk;
|
||||
if (isRegularHashtag) {
|
||||
channelName = '#$hashtag';
|
||||
// Regular hashtag - public derivation using SHA256
|
||||
psk = Channel.derivePskFromHashtag(hashtag);
|
||||
} else {
|
||||
|
|
@ -1068,8 +1069,8 @@ class _ChannelsScreenState extends State<ChannelsScreen>
|
|||
);
|
||||
return;
|
||||
}
|
||||
psk = selectedCommunity!
|
||||
.deriveCommunityHashtagPsk(hashtag);
|
||||
channelName = '${selectedCommunity!.name} #$hashtag';
|
||||
psk = selectedCommunity!.deriveCommunityHashtagPsk(hashtag);
|
||||
// Track in community's hashtag list
|
||||
await _communityStore.addHashtagChannel(
|
||||
selectedCommunity!.id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue