diff options
author | Simon MacMullen <simon@rabbitmq.com> | 2012-09-10 14:16:06 +0100 |
---|---|---|
committer | Simon MacMullen <simon@rabbitmq.com> | 2012-09-10 14:16:06 +0100 |
commit | d30dda5a869a60b64c98adf11095b62c9baa3843 (patch) | |
tree | 8cc691bd28fea1d824308a96168d1f5a2df70ded /src/rabbit_policy.erl | |
parent | 18e85807bee45cc33da857e047994ecfb79935da (diff) | |
download | rabbitmq-server-d30dda5a869a60b64c98adf11095b62c9baa3843.tar.gz |
Simplifybug25062
Diffstat (limited to 'src/rabbit_policy.erl')
-rw-r--r-- | src/rabbit_policy.erl | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/src/rabbit_policy.erl b/src/rabbit_policy.erl index 4eb7c2ba..69480c9c 100644 --- a/src/rabbit_policy.erl +++ b/src/rabbit_policy.erl @@ -129,12 +129,7 @@ match(Name, Policies) -> end. matches(#resource{name = Name}, Policy) -> - case re:run(binary_to_list(Name), - binary_to_list(pget(<<"pattern">>, Policy)), - [{capture, none}]) of - nomatch -> false; - match -> true - end. + match =:= re:run(Name, pget(<<"pattern">>, Policy), [{capture, none}]). sort_pred(A, B) -> pget(<<"priority">>, A, 0) >= pget(<<"priority">>, B, 0). |