Skip to content

Commit

Permalink
Fix QgsError.isEmpty() documentation
Browse files Browse the repository at this point in the history
The method checks if there is an empty message list. It will actually return `TRUE` if there is *no* error message and `FALSE` if there *is* an error.
  • Loading branch information
kannes authored and nyalldawson committed Feb 7, 2025
1 parent 702898b commit 7758257
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions python/PyQt6/core/auto_generated/qgserror.sip.in
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ Append new error message.

bool isEmpty() const;
%Docstring
Test if any error is set.
Test if no error is set.

:return: ``True`` if contains error
:return: ``False`` if contains error
%End

QString message( QgsErrorMessage::Format format = QgsErrorMessage::Html ) const;
Expand Down
4 changes: 2 additions & 2 deletions python/core/auto_generated/qgserror.sip.in
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,9 @@ Append new error message.

bool isEmpty() const;
%Docstring
Test if any error is set.
Test if no error is set.

:return: ``True`` if contains error
:return: ``False`` if contains error
%End

QString message( QgsErrorMessage::Format format = QgsErrorMessage::Html ) const;
Expand Down
4 changes: 2 additions & 2 deletions src/core/qgserror.h
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,8 @@ class CORE_EXPORT QgsError
void append( const QgsErrorMessage &message );

/**
* Test if any error is set.
* \returns TRUE if contains error
* Test if no error is set.
* \returns FALSE if contains error
*/
bool isEmpty() const { return mMessageList.isEmpty(); }

Expand Down

0 comments on commit 7758257

Please sign in to comment.