added optional passing of a date to date function
Merge pull request #238 from paczian/master

added optional passing of a date to date function