Modifications as described in bolt/bolt#615
Merge pull request #621 from ntomka/master

Modifications as described in bolt/bolt#615. Closes #615