[longomatch] Use Add instead of insert with bad indexes



commit a8656e9b100eab2b710c1db91949d25f03f9e35b
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Wed Sep 7 22:18:11 2011 +0200

    Use Add instead of insert with bad indexes

 LongoMatch/Store/Templates/CategoriesTemplate.cs |    2 +-
 LongoMatch/Store/Templates/TeamTemplate.cs       |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/LongoMatch/Store/Templates/CategoriesTemplate.cs b/LongoMatch/Store/Templates/CategoriesTemplate.cs
index 7a28538..7d98ed9 100644
--- a/LongoMatch/Store/Templates/CategoriesTemplate.cs
+++ b/LongoMatch/Store/Templates/CategoriesTemplate.cs
@@ -100,7 +100,7 @@ namespace LongoMatch.Store.Templates
 			cat.SubCategories.Add(localplayers);
 			cat.SubCategories.Add(visitorplayers);
 			cat.SubCategories.Add(period);
-			Insert(index, cat);
+			Add(cat);
 		}
 
 		public static Categories Load(string filePath) {
diff --git a/LongoMatch/Store/Templates/TeamTemplate.cs b/LongoMatch/Store/Templates/TeamTemplate.cs
index 49f5ae2..242d583 100644
--- a/LongoMatch/Store/Templates/TeamTemplate.cs
+++ b/LongoMatch/Store/Templates/TeamTemplate.cs
@@ -55,7 +55,7 @@ namespace LongoMatch.Store.Templates
 		}
 		
 		public void AddDefaultItem (int i) {
-			Insert(i, new Player {
+			Add(new Player {
 					Name = "Player " + i,
 					Birthday = new DateTime(),
 					Height = 1.80f,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]