[bugfix] Avoid NPE