mirror of https://github.com/apache/cloudstack.git
server: fix domain shared public template check (#6916)
Fixes #6885 Fixes the incorrect inverted check. Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com> Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
This commit is contained in:
parent
c8d27765d8
commit
6c436ec90e
|
|
@ -120,7 +120,7 @@ public class DomainChecker extends AdapterBase implements SecurityChecker {
|
|||
*/
|
||||
|
||||
private void checkPublicTemplateAccess(VirtualMachineTemplate template, Account owner, Account caller){
|
||||
if (!QueryService.SharePublicTemplatesWithOtherDomains.valueIn(owner.getDomainId()) ||
|
||||
if (QueryService.SharePublicTemplatesWithOtherDomains.valueIn(owner.getDomainId()) ||
|
||||
caller.getDomainId() == owner.getDomainId() ||
|
||||
_domainDao.isChildDomain(owner.getDomainId(), caller.getDomainId())) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue