mirror of
https://github.com/lempamo/Project-Unite.git
synced 2025-01-22 17:22:15 +00:00
add unite discriminator to entry id
This commit is contained in:
parent
52d46877c9
commit
90a96d093b
1 changed files with 1 additions and 1 deletions
|
@ -201,7 +201,7 @@ public ActionResult SubmitEntry(SubmitContestEntryViewModel model)
|
|||
entry.ContestId = model.ContestId;
|
||||
entry.VideoId = model.VideoID;
|
||||
string allowed = "abcdefghijklmnopqrstuvwxyz1234567890_";
|
||||
entry.Id = entry.Name.ToLower();
|
||||
entry.Id = entry.Name.ToLower() + "_" + db.ContestEntries.Count().ToString();
|
||||
foreach (var ch in entry.Id.ToCharArray())
|
||||
if (!allowed.Contains(ch))
|
||||
entry.Id = entry.Id.Replace(ch, '_');
|
||||
|
|
Loading…
Reference in a new issue