From 447a013299d148df12ff17306fff77bb7f85eba1 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 19 Apr 2017 13:13:16 +0200 Subject: clang-tidy readability-simplify-boolean-expr in dbaccess..framework Change-Id: I96e1bd4000f4ade6ccfac53c57653772b249df99 Reviewed-on: https://gerrit.libreoffice.org/36678 Tested-by: Jenkins Reviewed-by: Noel Grandin --- dbaccess/source/ui/relationdesign/RTableConnectionData.cxx | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'dbaccess/source/ui/relationdesign') diff --git a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx index 59733aa125a4..2f48f8edca69 100644 --- a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx +++ b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx @@ -174,10 +174,7 @@ bool ORelationTableConnectionData::checkPrimaryKey(const Reference< XPropertySet if ( nPrimKeysCount != aKeyColumns.getLength() ) return false; } - if ( !nPrimKeysCount || nPrimKeysCount != nValidLinesCount ) - return false; - - return true; + return nPrimKeysCount && nPrimKeysCount == nValidLinesCount; } bool ORelationTableConnectionData::IsConnectionPossible() -- cgit v1.2.3