summaryrefslogtreecommitdiff
path: root/framework/source/uiconfiguration/graphicnameaccess.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'framework/source/uiconfiguration/graphicnameaccess.cxx')
-rw-r--r--framework/source/uiconfiguration/graphicnameaccess.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/framework/source/uiconfiguration/graphicnameaccess.cxx b/framework/source/uiconfiguration/graphicnameaccess.cxx
index bdd4c1f2445c..fbc1d8ed43f2 100644
--- a/framework/source/uiconfiguration/graphicnameaccess.cxx
+++ b/framework/source/uiconfiguration/graphicnameaccess.cxx
@@ -43,10 +43,9 @@ void GraphicNameAccess::addElement( const OUString& rName, const uno::Reference<
uno::Any SAL_CALL GraphicNameAccess::getByName( const OUString& aName )
{
NameGraphicHashMap::const_iterator pIter = m_aNameToElementMap.find( aName );
- if ( pIter != m_aNameToElementMap.end() )
- return uno::makeAny( pIter->second );
- else
+ if ( pIter == m_aNameToElementMap.end() )
throw container::NoSuchElementException();
+ return uno::makeAny( pIter->second );
}
uno::Sequence< OUString > SAL_CALL GraphicNameAccess::getElementNames()