Explictly convert time to float before decimal for ruby < 1.9.3 compatibility.