Replaced Try::error with Error in master detector.

Review: https://reviews.apache.org/r/19299