Refactor _id attribute getter