diff --git a/code/solr/services/SolrService.php b/code/solr/services/SolrService.php index a521f34..c28b9e1 100644 --- a/code/solr/services/SolrService.php +++ b/code/solr/services/SolrService.php @@ -4,6 +4,7 @@ namespace SilverStripe\FullTextSearch\Solr\Services; use SilverStripe\Core\Config\Config; use SilverStripe\FullTextSearch\Solr\Solr; +use Silverstripe\Core\ClassInfo; Solr::include_client_api(); /** @@ -21,7 +22,8 @@ class SolrService extends SolrService_Core protected function coreCommand($command, $core, $params = array()) { $command = strtoupper($command); - + //get the non-namespaced name of the Solr core, since backslashes not valid characters + $core = ClassInfo::shortName($core); $params = array_merge($params, array('action' => $command, 'wt' => 'json')); $params[$command == 'CREATE' ? 'name' : 'core'] = $core;