fixed session grid storage and added before method to set it