I have this on my PageControllerDecorator:
public static $allowed_actions = array(
'UserPageComments'
);
public function UserPageComments() {
if($this->owner->data() && $this->owner->data()->ProvideComments) {
return new UserCommentInterface($this->owner, 'UserPageComments', $this->owner->data());
} else {
if(isset($_REQUEST['executeForm']) && $_REQUEST['executeForm'] == 'UserPageComments.PostCommentForm') {
echo "Comments have been disabled for this page";
die();
}
}
}
The problem is that whenever I submit the form, I get this error:
Action 'UserPageComments' isn't allowed on class Page_Controller
I've already made sure that the caches are flushed (even deleted) and ran dev/build.
I'm pretty sure this is an isolated case, or is just happening in my installation, because this custom comment interface was working before. No changes were made in the code but I'm working with other developers with other tasks on one project. I'm thinking this could be a result of some update the others have committed.
But I'm hoping someone could give any solution to this. Thanks.