added DateTimeEncoder to JsonResponse package to convert datetime object automagically if detected

Also replaced a try/except secquence in the JsonResponse function with a
functional equivalent