create an extension to active record