Fixed and documented stuff