Normalise trailing whitespace and line endings everywhere

This commit is contained in:
SteveSandersonMS
2016-03-01 01:10:43 +00:00
parent c425137423
commit 74cac774f8
174 changed files with 782 additions and 783 deletions

View File

@@ -60,4 +60,4 @@ namespace MusicStore.Models
[Compare("Password", ErrorMessage = "The password and confirmation password do not match.")]
public string ConfirmPassword { get; set; }
}
}
}

View File

@@ -7,7 +7,7 @@ namespace MusicStore.Models
{
public Album()
{
// TODO: Temporary hack to populate the orderdetails until EF does this automatically.
// TODO: Temporary hack to populate the orderdetails until EF does this automatically.
OrderDetails = new List<OrderDetail>();
}
@@ -37,4 +37,4 @@ namespace MusicStore.Models
public virtual ICollection<OrderDetail> OrderDetails { get; set; }
}
}
}

View File

@@ -9,4 +9,4 @@ namespace MusicStore.Models
[Required]
public string Name { get; set; }
}
}
}

View File

@@ -18,4 +18,4 @@ namespace MusicStore.Models
public virtual Album Album { get; set; }
}
}
}

View File

@@ -21,4 +21,4 @@ namespace MusicStore.Models
[JsonIgnore]
public virtual ICollection<Album> Albums { get; set; }
}
}
}

View File

@@ -31,4 +31,4 @@ namespace MusicStore.Models
base.OnModelCreating(builder);
}
}
}
}

View File

@@ -70,4 +70,4 @@ namespace MusicStore.Models
public ICollection<OrderDetail> OrderDetails { get; set; }
}
}
}

View File

@@ -11,4 +11,4 @@
public virtual Album Album { get; set; }
public virtual Order Order { get; set; }
}
}
}

View File

@@ -42,13 +42,13 @@ namespace MusicStore.Models
{
// Query in a separate context so that we can attach existing entities as modified
List<TEntity> existingData;
using (var scope = serviceProvider.GetRequiredService<IServiceScopeFactory>().CreateScope())
using (var db = scope.ServiceProvider.GetService<MusicStoreContext>())
{
existingData = db.Set<TEntity>().ToList();
}
using (var scope = serviceProvider.GetRequiredService<IServiceScopeFactory>().CreateScope())
using (var db = scope.ServiceProvider.GetService<MusicStoreContext>())
{
@@ -65,8 +65,8 @@ namespace MusicStore.Models
private static Album[] GetAlbums(string imgUrl, Dictionary<string, Genre> genres, Dictionary<string, Artist> artists)
{
var albums = new Album[]
{
var albums = new Album[]
{
new Album { Title = "The Best Of The Men At Work", Genre = genres["Pop"], Price = 8.99M, Artist = artists["Men At Work"], AlbumArtUrl = imgUrl },
new Album { Title = "...And Justice For All", Genre = genres["Metal"], Price = 8.99M, Artist = artists["Metallica"], AlbumArtUrl = imgUrl },
new Album { Title = "עד גבול האור", Genre = genres["World"], Price = 8.99M, Artist = artists["אריק אינשטיין"], AlbumArtUrl = imgUrl },
@@ -912,4 +912,4 @@ namespace MusicStore.Models
}
}
}
}
}

View File

@@ -8,9 +8,9 @@ namespace MusicStore.Models
public static class SentimentAnalysis
{
private static string[] positiveSentimentWords = new[] { "happy", "fun", "joy", "love", "delight", "bunny", "bunnies", "asp.net" };
private static string[] negativeSentimentWords = new[] { "sad", "pain", "despair", "hate", "scorn", "death", "package management" };
public static SentimentResult GetSentiment(string text) {
var numPositiveWords = CountWordOccurrences(text, positiveSentimentWords);
var numNegativeWords = CountWordOccurrences(text, negativeSentimentWords);
@@ -35,4 +35,4 @@ namespace MusicStore.Models
Positive,
}
}
}
}

View File

@@ -123,7 +123,7 @@ namespace MusicStore.Models
public decimal GetTotal()
{
// Multiply album price by count of that album to get
// Multiply album price by count of that album to get
// the current price for each of those albums in the cart
// sum all album price totals to get the cart total
@@ -190,7 +190,7 @@ namespace MusicStore.Models
if (string.IsNullOrWhiteSpace(sessionCookie))
{
//A GUID to hold the cartId.
//A GUID to hold the cartId.
cartId = Guid.NewGuid().ToString();
// Send cart Id as a cookie to the client.
@@ -204,4 +204,4 @@ namespace MusicStore.Models
return cartId;
}
}
}
}