jenkins-bot submitted this change.

View Change

Approvals: Matěj Suchánek: Looks good to me, approved jenkins-bot: Verified
[fix] use 'is' when comparing types

Change-Id: Iecb6582f30490b7d9aacaa2950afe21f0977e6b6
---
M pywikibot/site/_siteinfo.py
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pywikibot/site/_siteinfo.py b/pywikibot/site/_siteinfo.py
index 9ca6144..a798040 100644
--- a/pywikibot/site/_siteinfo.py
+++ b/pywikibot/site/_siteinfo.py
@@ -280,7 +280,7 @@
expiry = 0
# If expiry is a float or int convert to timedelta
# Note: bool is an instance of int
- if isinstance(expiry, float) or type(expiry) == int:
+ if isinstance(expiry, float) or type(expiry) is int:
expiry = datetime.timedelta(expiry)

# expire = 0 (or timedelta(0)) are always expired and their bool is

To view, visit change 673453. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: Iecb6582f30490b7d9aacaa2950afe21f0977e6b6
Gerrit-Change-Number: 673453
Gerrit-PatchSet: 1
Gerrit-Owner: Xqt <info@gno.de>
Gerrit-Reviewer: Matěj Suchánek <matejsuchanek97@gmail.com>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged