Index: binary-improvements/MapRendering/Web/Handlers/ApiHandler.cs
===================================================================
--- binary-improvements/MapRendering/Web/Handlers/ApiHandler.cs	(revision 326)
+++ binary-improvements/MapRendering/Web/Handlers/ApiHandler.cs	(revision 332)
@@ -4,4 +4,5 @@
 using System.Reflection;
 using AllocsFixes.NetConnections.Servers.Web.API;
+using UnityEngine.Profiling;
 
 namespace AllocsFixes.NetConnections.Servers.Web.Handlers {
@@ -40,4 +41,8 @@
 		}
 
+#if ENABLE_PROFILER
+		private static readonly CustomSampler apiHandlerSampler = CustomSampler.Create ("API_Handler");
+#endif
+
 		public override void HandleRequest (HttpListenerRequest req, HttpListenerResponse resp, WebConnection user,
 			int permissionLevel) {
@@ -55,5 +60,11 @@
 			if (apis.TryGetValue (apiName, out api)) {
 				try {
+#if ENABLE_PROFILER
+					apiHandlerSampler.Begin ();
+#endif
 					api.HandleRequest (req, resp, user, permissionLevel);
+#if ENABLE_PROFILER
+					apiHandlerSampler.End ();
+#endif
 					return;
 				} catch (Exception e) {
Index: binary-improvements/MapRendering/Web/Handlers/StaticHandler.cs
===================================================================
--- binary-improvements/MapRendering/Web/Handlers/StaticHandler.cs	(revision 326)
+++ binary-improvements/MapRendering/Web/Handlers/StaticHandler.cs	(revision 332)
@@ -13,5 +13,5 @@
 			string moduleName = null) : base (moduleName) {
 			this.staticPart = staticPart;
-			datapath = filePath;
+			datapath = filePath + (filePath [filePath.Length - 1] == '/' ? "" : "/");
 			this.cache = cache;
 			this.logMissingFiles = logMissingFiles;
@@ -22,5 +22,5 @@
 			string fn = req.Url.AbsolutePath.Remove (0, staticPart.Length);
 
-			byte[] content = cache.GetFileContent (datapath + "/" + fn);
+			byte[] content = cache.GetFileContent (datapath + fn);
 
 			if (content != null) {
@@ -31,6 +31,5 @@
 				resp.StatusCode = (int) HttpStatusCode.NotFound;
 				if (logMissingFiles) {
-					Log.Out ("Web:Static:FileNotFound: \"" + req.Url.AbsolutePath + "\" @ \"" + datapath + "/" +
-					         req.Url.AbsolutePath.Remove (0, staticPart.Length) + "\"");
+					Log.Out ("Web:Static:FileNotFound: \"" + req.Url.AbsolutePath + "\" @ \"" + datapath + fn + "\"");
 				}
 			}
Index: binary-improvements/MapRendering/Web/Handlers/UserStatusHandler.cs
===================================================================
--- binary-improvements/MapRendering/Web/Handlers/UserStatusHandler.cs	(revision 326)
+++ binary-improvements/MapRendering/Web/Handlers/UserStatusHandler.cs	(revision 332)
@@ -19,6 +19,5 @@
 				JSONObject permObj = new JSONObject ();
 				permObj.Add ("module", new JSONString (perm.module));
-				permObj.Add ("allowed",
-					new JSONBoolean (WebPermissions.Instance.ModuleAllowedWithLevel (perm.module, permissionLevel)));
+				permObj.Add ("allowed", new JSONBoolean (perm.permissionLevel >= permissionLevel));
 				perms.Add (permObj);
 			}
