From c775242a4ca9b4cc3606f76a4a21ae74a5481fcc Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=A9bastien=20Helleu?= <flashcode@flashtux.org>
Date: Sun, 16 Jan 2022 10:15:55 +0100
Subject: doc: remove useless comparison with empty string in Python examples
 (plugin API reference)

---
 doc/it/weechat_plugin_api.it.adoc | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

(limited to 'doc/it/weechat_plugin_api.it.adoc')

diff --git a/doc/it/weechat_plugin_api.it.adoc b/doc/it/weechat_plugin_api.it.adoc
index 8710dff8f..311ec3c2e 100644
--- a/doc/it/weechat_plugin_api.it.adoc
+++ b/doc/it/weechat_plugin_api.it.adoc
@@ -9644,9 +9644,9 @@ def my_process_cb(data, command, return_code, out, err):
         return weechat.WEECHAT_RC_OK
     if return_code >= 0:
         weechat.prnt("", "return_code = %d" % return_code)
-    if out != "":
+    if out:
         weechat.prnt("", "stdout: %s" % out)
-    if err != "":
+    if err:
         weechat.prnt("", "stderr: %s" % err)
     return weechat.WEECHAT_RC_OK
 
@@ -9664,9 +9664,9 @@ def my_process_cb(data, command, return_code, out, err):
         return weechat.WEECHAT_RC_OK
     if return_code >= 0:
         weechat.prnt("", "return_code = %d" % return_code)
-    if out != "":
+    if out:
         weechat.prnt("", "stdout: %s" % out)
-    if err != "":
+    if err:
         weechat.prnt("", "stderr: %s" % err)
     return weechat.WEECHAT_RC_OK
 
@@ -9877,9 +9877,9 @@ def my_process_cb(data, command, return_code, out, err):
         return weechat.WEECHAT_RC_OK
     if return_code >= 0:
         weechat.prnt("", "return_code = %d" % return_code)
-    if out != "":
+    if out:
         weechat.prnt("", "stdout: %s" % out)
-    if err != "":
+    if err:
         weechat.prnt("", "stderr: %s" % err)
     return weechat.WEECHAT_RC_OK
 
@@ -13266,7 +13266,7 @@ def buffer_clear(buffer: str) -> int: ...
 
 # esempio
 buffer = weechat.buffer_search("my_plugin", "my_buffer")
-if buffer != "":
+if buffer:
     weechat.buffer_clear(buffer)
 ----
 
-- 
cgit v1.2.3

