Removes extra zeros from time representation