Extract `#check_value_to_encode`.

It's unclear why travis is complaining about ABC complexity now.  It
certainly isn't doing so locally.  I suspect gem version mismatches,
but I don't know how that would arise either.
Merge pull request #114 from seomoz/phs/fix-abc-complexity

Extract `#check_value_to_encode`.