summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
Diffstat (limited to 'cui')
-rw-r--r--cui/source/dialogs/SpellDialog.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index d32a172249c5..8c7c59c0e3dc 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -524,11 +524,11 @@ namespace
OUString aString = rErrorText;
//dots are sometimes part of the spelled word but they are not necessarily part of the replacement
- bool bDot = !aString.isEmpty() && aString[aString.getLength() - 1] == '.';
+ bool bDot = aString.endsWith(".");
aString = rSuggestedReplacement;
- if(bDot && (aString.isEmpty() || aString[aString.getLength() - 1] != '.'))
+ if(bDot && (aString.isEmpty() || !aString.endsWith(".")))
aString += ".";
return aString;