Sep 27, 2019 12:10 PM|PatriceSc|LINK
But IMHO a major problem is to add some more code that fixes a value produced by wrong code rather than just fixing the wrong code so that it can directly give the correct result.
For now you are using a month value that can be 0 and that you are using directly to build a string. Pick a single approach and stick with it to avoid a confusion between the JS approach (month going from 0 to 11) ie you could :
- handle this using numbers and the usual convention (month from 1 to 12, increment year as needed)
- handle this using dates
- being in between is more likely to cause errors especially if not experienced with js programming