core: Use shorter scope for try catch block

There is no need to put try catch block on createTask since it
is already swallows the exception in CommandBase.

Change-Id: Icbdfa7acaac633a1e2010db5fd9fc9afe4fab219
Related to Bug-Url: https://bugzilla.redhat.com/1037441
Signed-off-by: Maor Lipchuk <mlipchuk@redhat.com>