bugfix for self::stat
Fixes #82