Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37871390
en ru br
ALT Linux repos
S:3.5.1-alt6

Group :: System/Servers
RPM: foreman

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Patch: invalid_premission.patch
Download


commit d7efc462e5018f55d5ce928836d433c5629dd808
Author: Pavel Skrylev <majioa@altlinux.org>
Date:   Fri Oct 29 21:09:09 2021 +0300
    fix: when invalid permisstions exception is thrown
    
    ! when invalid permisstions exception is thrown
diff --git a/app/models/role.rb b/app/models/role.rb
index 7add7585d..a8c97f3fb 100644
--- a/app/models/role.rb
+++ b/app/models/role.rb
@@ -333,7 +333,7 @@ class Role < ApplicationRecord
     collection = Permission.where(:name => perms).all
     if collection.size != perms.size
       raise ::Foreman::PermissionMissingException.new(N_("some permissions were not found: %s"),
-        not_found_permissions(collection.pluck(:name), perms))
+        not_found_permissions(collection.pluck(:name).map(&:to_sym), perms))
     end
     collection
   end
 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin