diff options
author | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-11-28 09:28:59 +0000 |
---|---|---|
committer | Caolán McNamara <caolan.mcnamara@collabora.com> | 2023-11-29 09:37:36 +0100 |
commit | bbbb509c3e3d2afa12392c521c382fb70c43d0a5 (patch) | |
tree | e714ba72c5a323301e38bfdd82bde5299ce81a3d /ucb/source | |
parent | da6547ff87d384d016619967359fe8bf340d1daf (diff) |
cid#1557589 Use of auto that causes a copy
Change-Id: Ie2c790420ce5fe2e2804f33ff552c2252dc0cc0b
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/160014
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Diffstat (limited to 'ucb/source')
-rw-r--r-- | ucb/source/ucp/cmis/cmis_content.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/ucb/source/ucp/cmis/cmis_content.cxx b/ucb/source/ucp/cmis/cmis_content.cxx index 1a499e1bdb3c..d07e389d2b05 100644 --- a/ucb/source/ucp/cmis/cmis_content.cxx +++ b/ucb/source/ucp/cmis/cmis_content.cxx @@ -1087,15 +1087,13 @@ namespace cmis std::vector< std::string > aPaths = pDoc->getPaths( ); if ( !aPaths.empty() ) { - auto sPath = aPaths.front( ); - aCmisUrl.setObjectPath( STD_TO_OUSTR( sPath ) ); + aCmisUrl.setObjectPath(STD_TO_OUSTR(aPaths.front())); } else { // We may have unfiled document depending on the server, those // won't have any path, use their ID instead - auto sId = pDoc->getId( ); - aCmisUrl.setObjectId( STD_TO_OUSTR( sId ) ); + aCmisUrl.setObjectId(STD_TO_OUSTR(pDoc->getId())); } return aCmisUrl.asString( ); } |