"use strict";var TcHmi;!function(TcHmi){!function(Functions){!function(Beckhoff){Beckhoff.CreateAuditLogEntry=function(ctx,entry){if(!ctx)throw new TypeError("Parameter 'ctx' must be defined.");if(!ctx.success||!ctx.error)throw new TypeError("Parameter 'ctx' must be defined properly. Either 'success' or 'error' or both are missing.");if("function"!=typeof ctx.success||"function"!=typeof ctx.error)throw new TypeError("Parameter 'ctx' must be defined properly. Either 'success' or 'error' or both are not of type 'function'.");TcHmi.Server.AuditTrail.createAuditLogEntry(entry,data=>{data.error===TcHmi.Errors.NONE?ctx.success():ctx.error(data.error,{code:data.error,message:TcHmi.Errors[data.error],reason:"Function: CreateAuditlLogEntry, Creating log entry failed.",domain:"Function",errors:data.details?[data.details]:void 0})})}}(Functions.Beckhoff||(Functions.Beckhoff={}))}(TcHmi.Functions||(TcHmi.Functions={}))}(TcHmi||(TcHmi={})),TcHmi.Functions.registerFunctionEx("CreateAuditLogEntry","TcHmi.Functions.Beckhoff",TcHmi.Functions.Beckhoff.CreateAuditLogEntry);