View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0004182SOGo Connectorwith SOGopublic2017-05-29 16:292017-06-14 08:29
Assigned Toludovic 
PlatformOSOS Version
Product Version31.0.3 
Target VersionFixed in Version 
Summary0004182: Migration code (from category property to categories property) deletes user data
DescriptionThis is for sogo-connector 31.0.4. In


there is this code segment:

  /* migration from MoreFunctionsblabla */
    let cardCategoriesValue = gEditCard.card.getProperty("Category", "");
    if (cardCategoriesValue.length > 0) {
        let migrationValue = cardCategoriesValue.split(", ").join("\u001A");
        gEditCard.card.setProperty("Categories", migrationValue);
        gEditCard.card.setProperty("Category", "");

As you can see, if there is some value in the "Category" property, it will be moved into the "Categories" property OVERWRITING any value present there.

If a user happens to use both properties, he will lose data without any notification or prompting. I have a pull request open for this, but it has been ignored so far: [^]

My suggestion is, to remove the auto-migration code, as you do not know, if the user wants to migrate or not.
TagsNo tags attached.
Attached Files

- Relationships Relation Graph ] Dependency Graph ]

-  Notes
User avatar (0011925)
ludovic (administrator)
2017-06-14 08:29

PR merged.

- Issue History
Date Modified Username Field Change
2017-05-29 16:29 jobisoft New Issue
2017-06-14 08:29 ludovic Note Added: 0011925
2017-06-14 08:29 ludovic Status new => resolved
2017-06-14 08:29 ludovic Resolution open => fixed
2017-06-14 08:29 ludovic Assigned To => ludovic

Copyright © 2000 - 2018 MantisBT Team
Powered by Mantis Bugtracker