Use inject in #define_historyable_attribute_history

You can safely ignore this pull request — I just love `Enumerator#inject` :smile: