private bool SkipChecks(bool checkContains, bool checkNotContains)
{
if (!TheSession.User.CanEditPage(TheSession.Page))
{
SkipPage("Page is protected");
return true;
}
if (!TheSession.User.CanCreatePage(TheSession.Page))
{
SkipPage("Page is protected from creation");
return true;
}
if (checkContains && skipIfContains.CheckEnabled && skipIfContains.Matches(TheArticle))
{
SkipPage(skipIfContains.SkipReason);
return true;
}
if (checkNotContains && skipIfNotContains.CheckEnabled && skipIfNotContains.Matches(TheArticle))
{
SkipPage(skipIfNotContains.SkipReason);
return true;
}
return false;
}