mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-15 19:54:57 +08:00
Validating archive route constraint
This commit is contained in:
@@ -27,6 +27,14 @@ namespace Orchard.Blogs.Routing {
|
||||
return false;
|
||||
}
|
||||
|
||||
try {
|
||||
// is this a valid date ?
|
||||
archiveData.ToDateTime();
|
||||
}
|
||||
catch {
|
||||
return false;
|
||||
}
|
||||
|
||||
return _blogPathConstraint.FindPath(path) != null;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user