#5394 and #4567
Merge pull request #152 from apatel/master

#5394 and #4567