|
@@ -547,7 +547,7 @@ namespace EVCB_OCPP.WSServer
|
|
|
// logger.LogDebug("------------New " + (session == null ? "Oops" : session.ChargeBoxId));
|
|
|
WriteMachineLog(session, "NewSessionConnected", "Connection", "");
|
|
|
|
|
|
- await mainDbService.UpdateMachineConnectionType(session.ChargeBoxId, session.Origin.Contains("https") ? 2 : 1);
|
|
|
+ await mainDbService.UpdateMachineConnectionType(session.ChargeBoxId, session.UriScheme.Contains("wss") ? 2 : 1);
|
|
|
|
|
|
}
|
|
|
catch (Exception ex)
|
|
@@ -889,7 +889,7 @@ namespace EVCB_OCPP.WSServer
|
|
|
session.IsAC = isAC.Value;
|
|
|
}
|
|
|
|
|
|
- await mainDbService.UpdateMachineConnectionType(session.ChargeBoxId, session.Origin.Contains("https") ? 2 : 1);
|
|
|
+ await mainDbService.UpdateMachineConnectionType(session.ChargeBoxId, session.UriScheme.Contains("wss") ? 2 : 1);
|
|
|
await webDbService.SetDefaultFee(session);
|
|
|
}
|
|
|
}
|