Commit dc73362c authored by Robert Rollins's avatar Robert Rollins

Issue #2135541: Applied similar fixes to the way that iCalcrator gets loaded.

Date iCal 3's use of the Libraries APIs was slightly less awful than 2's, but it
would still fail to properly detect an incorrectly installed iCalcreator.
parent 75a1825c
......@@ -17,8 +17,9 @@ class DateiCalFeedsParser extends FeedsParser {
* Implements FeedsParser::parse().
*/
public function parse(FeedsSource $source, FeedsFetcherResult $fetcher_result) {
if (!libraries_load('iCalcreator')) {
throw new DateIcalException(t('Unable to load the iCalcreator library. Please ensure that you have installed the library correctly.'));
$library = libraries_load('iCalcreator');
if (!$library['loaded']) {
throw new DateIcalException(t('Unable to load the iCalcreator library. Please ensure that it is properly installed.'));
}
$state = $source->state(FEEDS_PARSE);
......
......@@ -151,7 +151,7 @@ class date_ical_plugin_style_ical_feed extends views_plugin_style {
// Try to load the iCalcreator library.
$library = libraries_load('iCalcreator');
if (empty($library['loaded'])) {
if (!$library['loaded']) {
// The iCalcreator library isn't available, so we can't output anything.
$output = t('Please install the iCalcreator library to enable iCal output.');
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment