Fixed crash because of missing local variable. Optimized ability.rb a bit.
Merge pull request #111 from kaspernj/kj/comments/crash_because_of_missing_local_fix

Comments: Fixed crash because of missing local variable.