Made use of FromPrimitive, because IntConvertible was removed from rust.
Merge fix.
fixed typo