cleaned up extend util