Fixing issue #376