Improved extend.object