summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2021-04-08 10:53:10 +0200
committerMike Kaganski <mike.kaganski@collabora.com>2021-04-08 13:53:42 +0200
commitc0936ba2474f199b7242e2ca0a2d460647bc339e (patch)
treeb4d53751f50d45031ad8443479f172b11cf3193a /sw
parent396dfdd2164d095e4ec182956b31aca8c3908655 (diff)
These checks are not needed
Change-Id: Ic1a707010a4d17955e47a781355213044a699cf0 OUString::operator== will check if lengths are not equal anyway Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113756 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'sw')
-rw-r--r--sw/source/uibase/uiview/view.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/sw/source/uibase/uiview/view.cxx b/sw/source/uibase/uiview/view.cxx
index fc63c5568e42..c874e021375a 100644
--- a/sw/source/uibase/uiview/view.cxx
+++ b/sw/source/uibase/uiview/view.cxx
@@ -1171,9 +1171,8 @@ static bool lcl_IsOwnDocument( SwView& rView )
OUString Created = xDocProps->getAuthor();
OUString Changed = xDocProps->getModifiedBy();
OUString FullName = SW_MOD()->GetUserOptions().GetFullName();
- return (!FullName.isEmpty() &&
- (!Changed.isEmpty() && Changed == FullName )) ||
- (Changed.isEmpty() && !Created.isEmpty() && Created == FullName );
+ return !FullName.isEmpty()
+ && (Changed == FullName || (Changed.isEmpty() && Created == FullName));
}
void SwView::ReadUserData( const OUString &rUserData, bool bBrowse )