Bugfix - var $filename does not exist