Fixed runtime issues