When running an SQL feed programmatically, I'm getting notices as follows:
substr() expects parameter 1 to be string, array given FeedsFetcher.inc:75
The row that causes this is in the FeedsSQLFetcher class, row 40:
return new FeedsFetcherResult($results);
This runs the constructor with an array, and it excepts a string. I think we need a custom FeedsSQLFetcherResult class, without the sanitization.
Sorry about not providing a patch, in a hurry currently, but here is the gist of it:
Changed row:
return new FeedsSQLFetcherResult($results);
New class in FeedsSQLFetcher file:
/**
* Class for SQL fetcher results.
*/
class FeedsSQLFetcherResult extends FeedsFetcherResult {
protected $raw;
/**
* Constructor.
*/
public function __construct($raw) {
$this->raw = $raw;
}
/**
* @return
* The raw content from the source as an array.
*/
public function getRaw() {
return $this->raw;
}
}