public static T GetValue <T>(this StateBag bag, string key, T defaultValue) where T : class { if (!bag.HasKey(key)) { return(defaultValue); } return(bag[key] as T); }
public static T GetValue <T>(this StateBag bag, string key, T defaultValue) where T : class { if (!bag.HasKey(key)) { return(defaultValue); } return(bag[key] as T); }