added option to save password (or not)