Some code updates