added history controller
better errors gem and date parser for json