Fixes importing a plain text backup

fixes #2160 
fixes #2165
fixes #2196