Truncate to integer to work around a bug in node 0.10.30