fix datetime handling when NSNull