From 00b04ba41c975fcbbd44b79da3b2aafadacc6ad8 Mon Sep 17 00:00:00 2001
From: Steven Wittens <steven@10.no-reply.drupal.org>
Date: Sat, 23 Apr 2005 07:34:22 +0000
Subject: [PATCH] - Fix search index not wiping on admin settings change.

---
 modules/search.module        | 3 +--
 modules/search/search.module | 3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/modules/search.module b/modules/search.module
index 8b7b5cdb7199..6a43604d88b5 100644
--- a/modules/search.module
+++ b/modules/search.module
@@ -128,10 +128,9 @@ function search_admin() {
   if ($_POST) {
     // If the word length settings change, the index needs to be rebuilt.
     if (variable_get('minimum_word_size', 3) != $_POST['edit']['minimum_word_size']) {
-      // Note: ensure logical order of messages
-      system_settings_save();
       drupal_set_message(t('The index will be rebuilt.'));
       search_wipe();
+      system_settings_save();
     }
     else {
       system_settings_save();
diff --git a/modules/search/search.module b/modules/search/search.module
index 8b7b5cdb7199..6a43604d88b5 100644
--- a/modules/search/search.module
+++ b/modules/search/search.module
@@ -128,10 +128,9 @@ function search_admin() {
   if ($_POST) {
     // If the word length settings change, the index needs to be rebuilt.
     if (variable_get('minimum_word_size', 3) != $_POST['edit']['minimum_word_size']) {
-      // Note: ensure logical order of messages
-      system_settings_save();
       drupal_set_message(t('The index will be rebuilt.'));
       search_wipe();
+      system_settings_save();
     }
     else {
       system_settings_save();
-- 
GitLab