Added finalize for repl-widget