Code cleanup
More code cleanup
Create major grid update; add validation for grid layer id