added option to keep config