fix create and restore from command line