private String getApiKey ( CmsObject cms , String sitePath ) throws CmsException { String res = cms . readPropertyObject ( sitePath , CmsPropertyDefinition . PROPERTY_GOOGLE_API_KEY_WORKPLACE , true ) . getValue ( ) ; if ( CmsStringUtil . isEmptyOrWhitespaceOnly ( res ) ) { res = cms . readPropertyObject ( sitePath , CmsPropertyDefinition . PROPERTY_GOOGLE_API_KEY , true ) . getValue ( ) ; } return res ; }
Get the correct google api key . Tries to read a workplace key first .