Skip to content

Commit

Permalink
For bug 72155
Browse files Browse the repository at this point in the history
  • Loading branch information
JuliaRadzhabova committed Dec 20, 2024
1 parent 0bccc80 commit 643b785
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions apps/common/main/lib/view/AutoCorrectDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -94,18 +94,6 @@ define([
this.arrAddExceptions = {};
this.arrRemExceptions = {};

if (this.api)
_exciptionsLangs = this.api.asc_GetAutoCorrectSettings().get_FirstLetterExceptionManager().get_DefaultLangs() || [];
_exciptionsLangs.forEach(function(lang) {
path = me.appPrefix + "settings-letter-exception";

value = Common.Utils.InternalSettings.get(path + "-add-" + lang);
me.arrAddExceptions[lang] = value ? JSON.parse(value) : [];

value = Common.Utils.InternalSettings.get(path + "-rem-" + lang);
me.arrRemExceptions[lang] = value ? JSON.parse(value) : [];
});

Common.Views.AdvancedSettingsWindow.prototype.initialize.call(this, this.options);
},

Expand Down Expand Up @@ -337,8 +325,19 @@ define([
me.api.asc_SetAutoCorrectDoubleSpaceWithPeriod(checked);
});


// AutoCorrect
if (this.api)
_exciptionsLangs = this.api.asc_GetAutoCorrectSettings().get_FirstLetterExceptionManager().get_DefaultLangs() || [];
_exciptionsLangs.forEach(function(lang) {
var path = me.appPrefix + "settings-letter-exception";

var value = Common.Utils.InternalSettings.get(path + "-add-" + lang);
me.arrAddExceptions[lang] = value ? JSON.parse(value) : [];

value = Common.Utils.InternalSettings.get(path + "-rem-" + lang);
me.arrRemExceptions[lang] = value ? JSON.parse(value) : [];
});

var exciptionsActiveLang = Common.Utils.InternalSettings.get('settings-letter-exception-lang');
this.exceptionsLangCmb = new Common.UI.ComboBox({
el : $window.find('#auto-correct-exceptions-lang'),
Expand Down

0 comments on commit 643b785

Please sign in to comment.