Fixes access check for manage view.
Added forgotten IsMyEntity check and fixed a bug introduced by a rename in r2816.
Addresses Issue 584.
Patch by: Lennard de Rijk
Reviewed by: to-be-reviewed
Do not rely on dicts.merge to change target
Also make dicts.merge actually not touch target. This is much cleaner
than modifying in place, especially since we assign the result of the
dicts.merge call to target most of the time anyway.
Patch by: Sverre Rabbelier