blob: 69e4846bfa7a0e4701b61af6e5f2e9e9198529d5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
using System;
using System.Web.Mvc;
namespace PollutometerWebApi.Controllers
{
public class HomeController : Controller
{
public ActionResult Index()
{
var mvcName = typeof(Controller).Assembly.GetName();
var isMono = Type.GetType("Mono.Runtime") != null;
ViewData["Version"] = mvcName.Version.Major + "." + mvcName.Version.Minor;
ViewData["Runtime"] = isMono ? "Mono" : ".NET";
return View();
}
}
}
|