fixes parsing of flf files when last line is empty #10

Merged
merged 1 commit into from Oct 19, 2016

Conversation

Projects
None yet
2 participants
@common-nighthawk
Contributor

common-nighthawk commented Oct 17, 2016

i believe this fixes #5. it should now be possible to bring back fuzzy and wavy! (some other live fonts were also broken--like maxfour.)

load_extended_characters iterates over the last lines of the file, and tries to parse it as long as the line is not blank.

however, if i && i.empty? will not provide the expected result if the line is "" (in the file) aka nil (in ruby). rails has #blank, which would be perfect. but !i || i.empty? should work.
http://apidock.com/rails/Object/blank%3F

in short--it was the flf files with totally blank lines at the end that were breaking.

@miketierney

This comment has been minimized.

Show comment
Hide comment
@miketierney

miketierney Oct 17, 2016

Owner

The code change looks good and makes sense; I'll have to check it out when I'm off work. Thanks for submitting the PR!

Owner

miketierney commented Oct 17, 2016

The code change looks good and makes sense; I'll have to check it out when I'm off work. Thanks for submitting the PR!

@miketierney miketierney merged commit bf15977 into miketierney:master Oct 19, 2016

1 check failed

semaphoreci The build failed on Semaphore.
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment