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

Evaluate the channel name as a regex #14

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

oliwer
Copy link

@oliwer oliwer commented Aug 19, 2019

This allows the user to write somafm listen groove instead of somafm listen groovesalad. It's very convenient. The regex forces the user to write the first letters of the channel, it cannot match
the middle or the end. This is voluntary and should help avoiding unexpected results.

This allows the user to write `somafm listen groove` instead of
`somafm listen groovesalad`. It's very convenient. The regex forces
the user to write the first letters of the channel, it cannot match
the middle or the end. This is voluntary and should help avoiding
unexpected results.
@rockymadden
Copy link
Owner

@oliwer Love it. Are there any instances where a channel name is the prefix of another? I can't think of one off hand.

This guaranties we get the right result in case a channel name
is the same as another channel prefix. Also limit the number
of results to 1.
@oliwer
Copy link
Author

oliwer commented Aug 20, 2019

You're right. There is little chance this may ever happen, but I modified the condition to make sure it never happens!

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