[Minor] set username from certificate

This commit is contained in:
Reto Breitenmoser 2017-10-09 21:44:49 +02:00
parent c7fc11f563
commit 4adac09ab5
1 changed files with 1 additions and 2 deletions

View File

@ -141,9 +141,8 @@ public class DefaultStrolchPrivilegeHandler extends StrolchComponent implements
try (StrolchTransaction tx = realm.openTx(certificate, StrolchPrivilegeConstants.LOGIN)) {
tx.setSuppressDoNothingLogging(true);
tx.setSuppressAudits(true);
// the id should be set with the username!! But how to get from data?
Audit audit = tx.auditFrom(AccessType.CREATE, StrolchPrivilegeConstants.PRIVILEGE,
StrolchPrivilegeConstants.CERTIFICATE, "sso");
StrolchPrivilegeConstants.CERTIFICATE, certificate.getUsername());
tx.getAuditTrail().add(tx, audit);
}
return certificate;