Update directives.js

getYear() + 1900 is the same that getFullYear(), is simpler, and it is crossbrowser save.