ContextSet & Get, some code cleanup