Try/catch input sanitization
This commit is contained in:
@ -83,8 +83,12 @@ public class Posting
|
||||
}
|
||||
i++;
|
||||
}
|
||||
Regex boxRegex = new Regex(@"(Box \d+)");
|
||||
this.BoxNumber = boxRegex.Matches(this.NotesOnApplying)[0].Value.Replace("Box ", "");
|
||||
try
|
||||
{
|
||||
Regex boxRegex = new Regex(@"(Box \d+)");
|
||||
this.BoxNumber = boxRegex.Matches(this.NotesOnApplying)[0].Value.Replace("Box ", "");
|
||||
}
|
||||
catch (Exception) { }
|
||||
this.BargainingUnit = this.BargainingUnit.Replace("&", "&");
|
||||
this.VacancyID = id;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user