simoneeconomo / fancy_forms

10 stars 7 forks source link

Errors on non-HTML pages #4

Closed ahwayakchih closed 13 years ago

ahwayakchih commented 13 years ago

As noticed by Solutions-Nitriques in AjaxPage on the frontend thread, Better Forms creates errors on AjaxPage. It probably should check if Page is of HTMLPage class, e.g.,

    public function __appendAssets($context) {
        $page = $context['parent']->Page;
        if(!($page instanceof HTMLPage)) return;
        // [...]
    }
simoneeconomo commented 13 years ago

Thanks @ahwayakchih, I'll fix that tomorrow or later tonight. :)

simoneeconomo commented 13 years ago

Fixed.