core: findbugs + improving code

Fixing findbugs issue + improving code
readability

1. Removed dictemp + assigntmet
2. Changed the if instanceof map "pattern"

Change-Id: Icc7794df32b8d0f4cf08f7c5259b83a5a17db14f
Signed-off-by: Yair Zaslavsky <yzaslavs@redhat.com>