Rebase the master and merge changes of PR 121