return None instead of NULL for framebuffer and epaper
This commit is contained in:
parent
42f1d50acc
commit
57462092b5
@ -247,6 +247,9 @@ uint16_t common_hal_displayio_epaperdisplay_get_rotation(displayio_epaperdisplay
|
||||
}
|
||||
|
||||
mp_obj_t common_hal_displayio_epaperdisplay_get_root_group(displayio_epaperdisplay_obj_t *self) {
|
||||
if (self->core.current_group == NULL) {
|
||||
return mp_const_none;
|
||||
}
|
||||
return self->core.current_group;
|
||||
}
|
||||
|
||||
|
@ -363,6 +363,9 @@ void framebufferio_framebufferdisplay_reset(framebufferio_framebufferdisplay_obj
|
||||
}
|
||||
|
||||
mp_obj_t common_hal_framebufferio_framebufferdisplay_get_root_group(framebufferio_framebufferdisplay_obj_t *self) {
|
||||
if (self->core.current_group == NULL) {
|
||||
return mp_const_none;
|
||||
}
|
||||
return self->core.current_group;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user