mirror of
https://github.com/britzl/monarch.git
synced 2025-06-27 10:27:49 +02:00
Don't preload an already loaded screen
This commit is contained in:
parent
d1cf8281c9
commit
e570eac40b
@ -472,7 +472,7 @@ function M.preload(id, cb)
|
||||
assert(screens[id], ("There is no screen registered with id %s"):format(tostring(id)))
|
||||
|
||||
local screen = screens[id]
|
||||
if screen.preloaded then
|
||||
if screen.preloaded or screen.loaded then
|
||||
if cb then cb() end
|
||||
return
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user