do not dereference current outside guard condition
Summary:
if current can be null, then clearly the one if must be nested inside
the guard if lest it trips over the nullptr when calling name().
Test Plan: builds
Reviewers: Plasma, apol
Reviewed By: apol
Subscribers: plasma-devel
Tags: Plasma
Differential Revision: https://phabricator.kde.org/D22404