checkbefore add
better
datetime fix