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: hashtag matcher #1184

Merged
merged 1 commit into from
Nov 12, 2022
Merged

fix: hashtag matcher #1184

merged 1 commit into from
Nov 12, 2022

Conversation

foolo
Copy link
Contributor

@foolo foolo commented Nov 12, 2022

What does this PR do?

  • Detect hashtags with digits, for example #web3,
  • Detect hashtags with underscore, for example #foo_bar
  • Ignore hashtags with only digits and/or underscore, for example #123, #12_34, #_)

Before fix:
before
After fix:
after

Here is a live example post which contains #Web3 hashtag: https://lenster.xyz/posts/0x73a4-0x029e

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How should this be tested?

  • Create and view a post with the text. #lens #web3 #foo_bar #123 #_ #12_34 #foo! #bar? #test. dfg
  • Verify that only #lens, #web3, #foo_bar, #foo and #bar are detected as hashtags.

@foolo foolo requested a review from bigint as a code owner November 12, 2022 18:04
@vercel
Copy link

vercel bot commented Nov 12, 2022

@foolo is attempting to deploy a commit to the Lenster Team on Vercel.

A member of the Team first needs to authorize it.

@foolo
Copy link
Contributor Author

foolo commented Nov 12, 2022

@bigint I'm not sure if it's OK to just open a PR like this, without creating an issue first. Is it fine?, or should there always be an issue first?

@bigint
Copy link
Member

bigint commented Nov 12, 2022

It's perfectly fine 😊

@bigint bigint enabled auto-merge (squash) November 12, 2022 18:13
@bigint bigint merged commit 46e1995 into heyxyz:main Nov 12, 2022
@foolo
Copy link
Contributor Author

foolo commented Nov 12, 2022

Great, good to know! :)

@foolo foolo deleted the hashtag-matcher branch November 12, 2022 21:29
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.

None yet

2 participants