Hi all,
I believe I have found a bug with custom routes when using a multi-language set up. When multi-language is set up, this simple route below will fail with a 500.
c::set('routes', array(
array(
'pattern' => 'subscribe',
'action' => function() {
return false;
});
));
Note that redirecting to a page does work, but returning response objects also fails with 500.
Here is my error log:
[15-Jul-2015 07:51:39 UTC] PHP Warning: Cannot modify header information - headers already sent by (output started at /Users/Shared/work/work_server/kirbysite/site/languages/de.php:1) in /Users/Shared/work/work_server/kirbysite/kirby/toolkit/lib/header.php on line 92
[15-Jul-2015 07:51:51 UTC] PHP Notice: Trying to get property of non-object in /Users/Shared/work/work_server/kirbysite/kirby/branches/multilang/site.php on line 190
[15-Jul-2015 07:51:51 UTC] PHP Notice: Trying to get property of non-object in /Users/Shared/work/work_server/kirbysite/kirby/branches/multilang/site.php on line 190
[15-Jul-2015 07:51:51 UTC] PHP Fatal error: Call to a member function code() on a non-object in /Users/Shared/work/work_server/kirbysite/kirby/kirby.php on line 526
[15-Jul-2015 07:51:51 UTC] PHP Warning: Cannot modify header information - headers already sent by (output started at /Users/Shared/work/work_server/kirbysite/site/languages/de.php:1) in /Users/Shared/work/work_server/net.tinkerbots/kirby/toolkit/lib/header.php on line 92
Any ideas why?
Cheers,
Peter