quick fix
This commit is contained in:
parent
7f6560a6aa
commit
7a9d63b1a4
|
@ -37,12 +37,13 @@ namespace bahnplan.web.Pages {
|
|||
return;
|
||||
}
|
||||
|
||||
Legs = db.Legs.Where(p => p.TripId == int.Parse(Request.Query["id"])).OrderBy(p => p.DepTime).ToList();
|
||||
|
||||
if (!db.Legs.Any(p => p.TripId == int.Parse(Request.Query["id"]))) {
|
||||
RedirToIndex = true;
|
||||
return;
|
||||
}
|
||||
|
||||
Legs = db.Legs.Where(p => p.TripId == int.Parse(Request.Query["id"])).OrderBy(p => p.DepTime).ToList();
|
||||
User = db.Users.First(p => p.UserId == Legs.First().UserId).Username;
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue