X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/cda441b1b6e50811c7dbd8d5c61ead1b39c91857..0eb72b526bf8bbb011551ecf019f604e17a534f1:/apps/workbench/app/models/authorized_key.rb diff --git a/apps/workbench/app/models/authorized_key.rb b/apps/workbench/app/models/authorized_key.rb index 724c996e4a..9809eef0e3 100644 --- a/apps/workbench/app/models/authorized_key.rb +++ b/apps/workbench/app/models/authorized_key.rb @@ -1,9 +1,17 @@ +# Copyright (C) The Arvados Authors. All rights reserved. +# +# SPDX-License-Identifier: AGPL-3.0 + class AuthorizedKey < ArvadosBase - def attribute_editable? attr, *args - if attr.to_s == 'authorized_user_uuid' - current_user and current_user.is_admin + def attribute_editable?(attr, ever=nil) + if (attr.to_s == 'authorized_user_uuid') and (not ever) + current_user.andand.is_admin else super end end + + def self.creatable? + false + end end