Merged from safe customization.
Fix merged conflict from inasafe.