Fix runtime issues