Commit b8e245a9 authored by Rushan Suleymanov's avatar Rushan Suleymanov Committed by Commit Bot

[Sync] Remove UpdateGUIDWithNodeReplacement feature toggle

The feature toggle was enabled by default in M83.

Change-Id: I9afb7659990af267540dcd044bafda3dc1c3d8bc
Bug: None
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2426426Reviewed-by: default avatarMikel Astiz <mastiz@chromium.org>
Commit-Queue: Rushan Suleymanov <rushans@google.com>
Cr-Commit-Position: refs/heads/master@{#810104}
parent eb97bb4a
...@@ -303,9 +303,7 @@ void UpdateBookmarkNodeFromSpecifics( ...@@ -303,9 +303,7 @@ void UpdateBookmarkNodeFromSpecifics(
// resolving any conflict in GUID. Either GUIDs are the same, or the GUID in // resolving any conflict in GUID. Either GUIDs are the same, or the GUID in
// specifics is invalid, and hence we can ignore it. // specifics is invalid, and hence we can ignore it.
DCHECK(specifics.guid() == node->guid() || DCHECK(specifics.guid() == node->guid() ||
!base::IsValidGUIDOutputString(specifics.guid()) || !base::IsValidGUIDOutputString(specifics.guid()));
!base::FeatureList::IsEnabled(
switches::kUpdateBookmarkGUIDWithNodeReplacement));
if (!node->is_folder()) { if (!node->is_folder()) {
model->SetURL(node, GURL(specifics.url())); model->SetURL(node, GURL(specifics.url()));
...@@ -322,11 +320,6 @@ const bookmarks::BookmarkNode* ReplaceBookmarkNodeGUID( ...@@ -322,11 +320,6 @@ const bookmarks::BookmarkNode* ReplaceBookmarkNodeGUID(
const bookmarks::BookmarkNode* node, const bookmarks::BookmarkNode* node,
const std::string& guid, const std::string& guid,
bookmarks::BookmarkModel* model) { bookmarks::BookmarkModel* model) {
if (!base::FeatureList::IsEnabled(
switches::kUpdateBookmarkGUIDWithNodeReplacement)) {
return node;
}
const bookmarks::BookmarkNode* new_node;
DCHECK(base::IsValidGUIDOutputString(guid)); DCHECK(base::IsValidGUIDOutputString(guid));
if (node->guid() == guid) { if (node->guid() == guid) {
...@@ -334,6 +327,7 @@ const bookmarks::BookmarkNode* ReplaceBookmarkNodeGUID( ...@@ -334,6 +327,7 @@ const bookmarks::BookmarkNode* ReplaceBookmarkNodeGUID(
return node; return node;
} }
const bookmarks::BookmarkNode* new_node = nullptr;
if (node->is_folder()) { if (node->is_folder()) {
new_node = new_node =
model->AddFolder(node->parent(), node->parent()->GetIndexOf(node), model->AddFolder(node->parent(), node->parent()->GetIndexOf(node),
......
...@@ -9,10 +9,6 @@ namespace switches { ...@@ -9,10 +9,6 @@ namespace switches {
const base::Feature kSyncDoNotCommitBookmarksWithoutFavicon = { const base::Feature kSyncDoNotCommitBookmarksWithoutFavicon = {
"SyncDoNotCommitBookmarksWithoutFavicon", base::FEATURE_ENABLED_BY_DEFAULT}; "SyncDoNotCommitBookmarksWithoutFavicon", base::FEATURE_ENABLED_BY_DEFAULT};
// Enables updating a BookmarkNode's GUID by replacing the node itself.
const base::Feature kUpdateBookmarkGUIDWithNodeReplacement{
"UpdateGUIDWithNodeReplacement", base::FEATURE_ENABLED_BY_DEFAULT};
// Enables the GUID-aware merge algorithm. // Enables the GUID-aware merge algorithm.
const base::Feature kMergeBookmarksUsingGUIDs{"MergeBookmarksUsingGUIDs", const base::Feature kMergeBookmarksUsingGUIDs{"MergeBookmarksUsingGUIDs",
base::FEATURE_ENABLED_BY_DEFAULT}; base::FEATURE_ENABLED_BY_DEFAULT};
......
...@@ -10,7 +10,6 @@ ...@@ -10,7 +10,6 @@
namespace switches { namespace switches {
extern const base::Feature kSyncDoNotCommitBookmarksWithoutFavicon; extern const base::Feature kSyncDoNotCommitBookmarksWithoutFavicon;
extern const base::Feature kUpdateBookmarkGUIDWithNodeReplacement;
extern const base::Feature kMergeBookmarksUsingGUIDs; extern const base::Feature kMergeBookmarksUsingGUIDs;
// TODO(crbug.com/1066962): remove this code when most of bookmarks are // TODO(crbug.com/1066962): remove this code when most of bookmarks are
// reuploaded. // reuploaded.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment