aboutsummaryrefslogtreecommitdiffstats
path: root/app/models/api
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/api')
-rw-r--r--app/models/api/v1/api_key.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/app/models/api/v1/api_key.rb b/app/models/api/v1/api_key.rb
index 09c6f77ac..890e8e175 100644
--- a/app/models/api/v1/api_key.rb
+++ b/app/models/api/v1/api_key.rb
@@ -1,7 +1,8 @@
module Api
module V1
- class ApiKey < ::ActiveRecord::Base
- has_paper_trail
+ class ApiKey < ::ApplicationModel
+ include MetadataSupport
+ has_metadata
before_create :generate_access_token
belongs_to :referential, :class_name => '::Referential'
belongs_to :organisation, :class_name => '::Organisation'
@@ -47,4 +48,3 @@ module Api
end
end
end
-