Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
typos
  • Loading branch information
3nids committed Sep 10, 2020
1 parent 86c4aaa commit fa18514
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/qgis.h
Expand Up @@ -513,7 +513,7 @@ template<class T> QString qgsEnumValueToKey( const T &value ) SIP_SKIP
/**
* Returns the value corresponding to the given \a key of an enum.
* If the key is invalid, it will return the \a defaultValue.
* If \a tryValueAsKey is true, it will try to use convert the string key to an enum value
* If \a tryValueAsKey is true, it will try to convert the string key to an enum value
* \since QGIS 3.6
*/
template<class T> T qgsEnumKeyToValue( const QString &key, const T &defaultValue, bool tryValueAsKey = true ) SIP_SKIP
Expand All @@ -532,7 +532,7 @@ template<class T> T qgsEnumKeyToValue( const QString &key, const T &defaultValue
if ( tryValueAsKey )
{
bool canConvert = false;
int intValue = key.toInt( &ok );
int intValue = key.toInt( &canConvert );
if ( canConvert && metaEnum.valueToKey( intValue ) )
{
return static_cast<T>( intValue );
Expand Down

0 comments on commit fa18514

Please sign in to comment.