Backward compatibility of 2.x with 4.6
Hello !
It seems that version 2.0 breaks backward compatibility with 4.6 platforms on the 'Find rules' action.
Issue appears to be the call to function: **CRM_Utils_System::getUrlPath()** which doesn't exist on 4.6 versions.
File: CRM/Civirules/Form/Search/Rules.php
Line 22:
```PHP
$session = CRM_Core_Session::singleton();
$url = CRM_Utils_System::getUrlPath();
```
To fix this, I added a condition on that part:
```PHP
// Set the user context
$session = CRM_Core_Session::singleton();
if ($this->_domainversion <= 4.6) {
// Backwards compatible with 4.6 systems
$url = CRM_Utils_System::currentPath();
} else {
$url = CRM_Utils_System::getUrlPath();
}
```
I'm also attaching a patch for that.
[civirules-2.0-fix-compatibility-4.6.patch](/uploads/61929e9ea5675543028841e91e40dd01/civirules-2.0-fix-compatibility-4.6.patch)
issue