More fixes.
Added context restriction.
More fixes.