comparison ServerMonitor/Objects/Checks/HttpCheck.cs @ 39:7645122aa7a9

Get it working under Mono
author Brad Greco <brad@bgreco.net>
date Tue, 09 Jun 2020 20:59:00 -0400
parents b713b9db4c82
children
comparison
equal deleted inserted replaced
38:8ab98a803d39 39:7645122aa7a9
131 message += "At least one check must be enabled." + Environment.NewLine; 131 message += "At least one check must be enabled." + Environment.NewLine;
132 if (CheckResponseBody && ResponseBodyUseRegex) 132 if (CheckResponseBody && ResponseBodyUseRegex)
133 { 133 {
134 try 134 try
135 { 135 {
136 Regex re = new Regex(ResponseBodyPattern); 136 new Regex(ResponseBodyPattern);
137 } 137 }
138 catch (ArgumentException) 138 catch (ArgumentException)
139 { 139 {
140 message += "Invalid regular expression for response body." + Environment.NewLine; 140 message += "Invalid regular expression for response body." + Environment.NewLine;
141 } 141 }