diff --git a/src/Microsoft.AspNet.Mvc.Razor/RazorPage.cs b/src/Microsoft.AspNet.Mvc.Razor/RazorPage.cs
index bde2981b27..27b0c8b620 100644
--- a/src/Microsoft.AspNet.Mvc.Razor/RazorPage.cs
+++ b/src/Microsoft.AspNet.Mvc.Razor/RazorPage.cs
@@ -48,18 +48,7 @@ namespace Microsoft.AspNet.Mvc.Razor
///
/// An representing the current request execution.
///
- public HttpContext Context
- {
- get
- {
- if (ViewContext == null)
- {
- return null;
- }
-
- return ViewContext.HttpContext;
- }
- }
+ public HttpContext Context => ViewContext?.HttpContext;
///
public string Path { get; set; }
@@ -102,41 +91,18 @@ namespace Microsoft.AspNet.Mvc.Razor
///
/// Gets the of the current logged in user.
///
- public virtual ClaimsPrincipal User
- {
- get
- {
- if (Context == null)
- {
- return null;
- }
-
- return Context.User;
- }
- }
+ public virtual ClaimsPrincipal User => Context?.User;
///
/// Gets the dynamic view data dictionary.
///
- public dynamic ViewBag
- {
- get
- {
- return ViewContext?.ViewBag;
- }
- }
+ public dynamic ViewBag => ViewContext?.ViewBag;
///
/// Gets the from the .
///
/// Returns null if is null.
- public ITempDataDictionary TempData
- {
- get
- {
- return ViewContext?.TempData;
- }
- }
+ public ITempDataDictionary TempData => ViewContext?.TempData;
///
public Func RenderBodyDelegateAsync { get; set; }