private void waitForThread() {
        if ((this.thread != null) && this.thread.isAlive()) {
            try {
                this.thread.join();
            } catch (final InterruptedException e) {
                plugin.getLogger().log(Level.SEVERE, null, e);
            }
        }
    }