adds master handling.
Merge pull request #77 from birkin/master

adds master handling.