BUGFIX: workaround for threading problems