server: Fix crash when import is cancelled

Signed-off-by: Jens Georg <mail@jensge.org>

https://bugzilla.gnome.org/show_bug.cgi?id=734302