Rendering only when something changes
NullPointerException fix