Added Return and Extend function