Fix datetime regression

Refs #740.