replaced id by instancetype and adjusted indentation