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

Invalid words bug #30

Open
schlomok opened this issue Apr 6, 2016 · 5 comments
Open

Invalid words bug #30

schlomok opened this issue Apr 6, 2016 · 5 comments

Comments

@schlomok
Copy link

schlomok commented Apr 6, 2016

If you use a word that is not allowed (for example, ironically, the word application), you can press a character (space, period, etc.) and start a new word afterwards, that old word remains

@clickthisnick
Copy link

Same with tilda. "NARWHAL~ " is a valid word.

@gendium
Copy link

gendium commented Apr 21, 2016

I was thinking of creating a function that will just check the string if it has a character that is not a letter, which would then return false to the function that checks the word itself.

@gendium
Copy link

gendium commented Apr 28, 2016

I submitted a possible solution. I'm pretty sure it works (logically at least), but at least the idea is still there.

@mortenjust
Copy link
Owner

That pull request was not Swift :)

@mortenjust
Copy link
Owner

If anyone wants to think about a solution for this one, this may be the way to approach it;

  1. Is the character to the right of the word a punctuation character? If so, delete it.
  2. Is the character to the right of the word a space? If so, is the character to the right of the space either EOF or space? If so, delete the space.

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

No branches or pull requests

4 participants