Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions BionicMonitorService/Services/WatcherService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ namespace BionicMonitorService.Services {
public class WatcherService : IWatcherService {
private static readonly Regex SignalRRegEx =
new Regex(
@"<script src=""https:\/\/unpkg\.com\/@aspnet\/signalr@\d?\.\d?\.\d?\/dist\/browser\/signalr\.min\.js""><\/script>",
@"<script WARNING=""Injected by Bionic Monitor"" src=""https:\/\/unpkg\.com\/@aspnet\/signalr@\d?\.\d?\.\d?\/dist\/browser\/signalr\.min\.js""><\/script>",
RegexOptions.Compiled);
private static readonly Regex ReloaderRegEx= new Regex(
@"<script src=""bionic/reloader.js""></script>",
@"<script WARNING=""Injected by Bionic Monitor"" src=""bionic/reloader.js""></script>",
RegexOptions.Compiled);

private List<FileSystemWatcher> _watchers = new List<FileSystemWatcher>();
Expand Down Expand Up @@ -99,7 +99,7 @@ private void InjectReloader(string path) {
modified = true;
all = all.Replace(
"</head>",
$"<script src=\"https://unpkg.com/@aspnet/[email protected]/dist/browser/signalr.min.js\"></script>\n</head>"
"<script WARNING=\"Injected by Bionic Monitor\" src=\"https://unpkg.com/@aspnet/[email protected]/dist/browser/signalr.min.js\"></script>\n</head>"
);
}

Expand All @@ -108,7 +108,7 @@ private void InjectReloader(string path) {
modified = true;
all = all.Replace(
"</head>",
$"<script src=\"bionic/reloader.js\"></script>\n</head>"
"<script WARNING=\"Injected by Bionic Monitor\" src=\"bionic/reloader.js\"></script>\n</head>"
);
}

Expand Down