From a29a2a0fa424d116dd50c9a658409ac4cdf2ee62 Mon Sep 17 00:00:00 2001 From: Thomas Keller Date: Thu, 7 Oct 2010 01:05:15 +0000 Subject: [PATCH] The connection list view could never work with this messy backend. --- src/IDF/Scm/Monotone/Usher.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/IDF/Scm/Monotone/Usher.php b/src/IDF/Scm/Monotone/Usher.php index 5e55e08..ed423ea 100644 --- a/src/IDF/Scm/Monotone/Usher.php +++ b/src/IDF/Scm/Monotone/Usher.php @@ -76,7 +76,7 @@ class IDF_Scm_Monotone_Usher $single_conns = preg_split('/[ ]/', $conn); $ret = array(); foreach ($single_conns as $conn) { - preg_match('/\(\w+\)([^:]):(\d+)/', $conn, $matches); + preg_match('/\((\w+)\)([^:]+):(\d+)/', $conn, $matches); $ret[$matches[1]][] = (object)array( 'server' => $matches[1], 'address' => $matches[2], @@ -84,6 +84,12 @@ class IDF_Scm_Monotone_Usher ); } + if ($server !== null) { + if (array_key_exists($server, $ret)) + return $ret[$server]; + return array(); + } + return $ret; }