added optional destroy param to close() and closeSubState() methods