Skip to content

Commit

Permalink
Merge pull request #86 from andreasringdal/feature/ar/#85_multiline_j…
Browse files Browse the repository at this point in the history
…son_message

#85 Multiline Json regex
  • Loading branch information
dallmann-consulting authored Dec 4, 2024
2 parents 6a62e2c + 7c6f340 commit 3427449
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion OCPP.Core.Server/OCPPMiddleware.cs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public partial class OCPPMiddleware
// RegExp for splitting ocpp message parts
// ^\[\s*(\d)\s*,\s*\"([^"]*)\"\s*,(?:\s*\"(\w*)\"\s*,)?\s*(.*)\s*\]$
// Third block is optional, because responses don't have an action
private static string MessageRegExp = "^\\[\\s*(\\d)\\s*,\\s*\"([^\"]*)\"\\s*,(?:\\s*\"(\\w*)\"\\s*,)?\\s*(.*)\\s*\\]$";
private static string MessageRegExp = "^\\[\\s*(\\d+)\\s*,\\s*\"([^\"]+)\"\\s*,\\s*(?:\\s*\"(\\w+)\"\\s*,)?\\s*(\\{[^}]+\\}|\\{[\\s\\S]*?\\})\\s*\\]$";

private readonly RequestDelegate _next;
private readonly ILoggerFactory _logFactory;
Expand Down

0 comments on commit 3427449

Please sign in to comment.