D27722: [resources/maildir] Don't save "file:" schema to the config

Igor Poboiko noreply at phabricator.kde.org
Sat Feb 29 20:00:34 GMT 2020


poboiko added a comment.


  In D27722#619699 <https://phabricator.kde.org/D27722#619699>, @dvratil wrote:
  
  > Nicely done!
  >
  > Is there a way to auto-fix this for existing users?
  
  
  We can add temporary code that strips the schema, for example, inside `ensureSaneConfguration()`. Something like:
  
    QUrl url(mSettings->path());
    mSettings->setPath(url.isLocalFile() ? url.toLocalFile() : url.path());
    mSettings->save();
  
  will do the trick (I've just tried it, it seems to be working). I can add it to the patch.
  
  However, there is also potential issue regarding user data that could have ended up inside `$HOME/file:/$HOME/path/to/maildir`. 
  I guess it would probably be nice to merge it somehow with the "correct" maildir inside `$HOME/path/to/maildir`.
  But that would require some sort of migrator, not really sure what is the best way to do it.

REPOSITORY
  R44 KDE PIM Runtime

REVISION DETAIL
  https://phabricator.kde.org/D27722

To: poboiko, dvratil, mlaurent
Cc: kde-pim, fbampaloukas, dcaliste, dvasin, rodsevich, winterz, vkrause, mlaurent, knauss, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20200229/fb948c26/attachment.html>


More information about the kde-pim mailing list