drivers/display/lcd160cr: Use isinstance() for type checking.

Fixes linter warning E721, expanded in Ruff 823 to include
direct comparison against built-in types.
pull/713/head
Angus Gratton 2023-08-09 18:59:03 +10:00
rodzic 01ab7ba6e2
commit 674e734a1c
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -5,7 +5,7 @@ import time, math, framebuf, lcd160cr
def get_lcd(lcd):
if type(lcd) is str:
if isinstance(lcd, str):
lcd = lcd160cr.LCD160CR(lcd)
return lcd