Fix moodle dir detection not working when combined with symbolic links