diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-28 03:09:02 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2018-10-28 08:23:32 +0100 |
commit | 36880d76299e913761f03bbde1b6ca6bea393b5a (patch) | |
tree | 05a880ec60124a405a2d817b2598f23a2bbba423 /scripting | |
parent | 85985a6ad85ebd3debf63e286dacbe5945178796 (diff) |
tdf#120703 PVS: V547 Expression is always true/false
Change-Id: I1e5098e11f1e5e2f7c5518ea05c57512f58b585b
Reviewed-on: https://gerrit.libreoffice.org/62464
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'scripting')
-rw-r--r-- | scripting/source/provider/MasterScriptProvider.cxx | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/scripting/source/provider/MasterScriptProvider.cxx b/scripting/source/provider/MasterScriptProvider.cxx index fa4b53100fa8..6854d6283dc0 100644 --- a/scripting/source/provider/MasterScriptProvider.cxx +++ b/scripting/source/provider/MasterScriptProvider.cxx @@ -398,8 +398,6 @@ MasterScriptProvider::getName() Sequence< Reference< browse::XBrowseNode > > SAL_CALL MasterScriptProvider::getChildNodes() { - if ( !providerCache() ) - throw RuntimeException( "MasterScriptProvider::getAllProviders, cache not initialised" ); Sequence< Reference< provider::XScriptProvider > > providers = providerCache()->getAllProviders(); sal_Int32 size = providers.getLength(); @@ -525,12 +523,6 @@ MasterScriptProvider::insertByName( const OUString& aName, const Any& aElement ) // TODO for library package parse the language, for the moment will try // to get each provider to process the new Package, the first one the succeeds // will terminate processing - if ( !providerCache() ) - { - throw RuntimeException( - "insertByName cannot instantiate " - "child script providers." ); - } const bool bSuccess = FindProviderAndApply( *providerCache(), [&aName, &aElement](Reference<container::XNameContainer>& xCont) { xCont->insertByName(aName, aElement); @@ -570,13 +562,6 @@ MasterScriptProvider::removeByName( const OUString& Name ) // TODO for Script library package url parse the language, // for the moment will just try to get each provider to process remove/revoke // request, the first one the succeeds will terminate processing - - if ( !providerCache() ) - { - throw RuntimeException( - "removeByName() cannot instantiate " - "child script providers." ); - } const bool bSuccess = FindProviderAndApply( *providerCache(), [&Name](Reference<container::XNameContainer>& xCont) { xCont->removeByName(Name); @@ -637,13 +622,6 @@ MasterScriptProvider::hasByName( const OUString& aName ) // for the moment will just try to get each provider to see if the // package exists in any provider, first one that succeed will // terminate the loop - - if ( !providerCache() ) - { - throw RuntimeException( - "removeByName() cannot instantiate " - "child script providers." ); - } result = FindProviderAndApply( *providerCache(), [&aName](Reference<container::XNameContainer>& xCont) { return xCont->hasByName(aName); |