public ActionResult Index() { ViewBag.Message = "Grab your friends now!"; TagCloud test; ComUsers com = new ComUsers(); if (com.IsTokenValid(HttpContext)) { test = com.GetPublicTagStats(4); } else { test = new TagCloud(); } return(View(test)); }
protected override bool AuthorizeCore(HttpContextBase httpContext) { bool check = false; if (Types != null) { foreach (int i in Types) { if (comUsers.IsAuthorized(httpContext, i)) { check = true; } } } else { check = comUsers.IsTokenValid(httpContext); } return(check); }