Sorry I don't have time to provide a proper patch, but this is a quick fix:

Simply replace http://drupalcode.org/project/user_relationships.git/blob/refs/heads/7.x... with

    if (variable_get('user_relationships_restrict_privatemsg', 'all') == 'all_overridable' && user_relationships_user_access('maintain @relationship relationships', NULL, $form['#user'])) {

Comments

Status:Needs review» Fixed

But except the maintainers to have time to manually apply these changes? ;)

Commited.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.