fixing issue #337