Skip to content
This repository has been archived by the owner on Jun 15, 2022. It is now read-only.

Commit

Permalink
Merge pull request #58 from jwineman/jwineman/subdomain-error-logging
Browse files Browse the repository at this point in the history
Fixing a bug in Cpanel 11.52 where Cpanel::JSON doesn't want to be us…
  • Loading branch information
dfritsch committed Oct 8, 2015
2 parents b6f71a0 + c97434c commit 586853d
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions cloudflare/Cpanel/CloudFlare/Config.pm
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@ use Cpanel::CloudFlare::Helper();
## Global cPanel plugin configuration
my $cf_config_file = "/usr/local/cpanel/etc/cloudflare.json";

## stores the loaded configuration data within the static variable `$data`
my $data = Cpanel::CloudFlare::Helper::__get_json_loadfile_function()->($cf_config_file);
my $data;

# Cpanel::JSON::_create_new_json_object in 11.52 does not like being called in BEGIN or CHECK
sub INIT {
## stores the loaded configuration data within the static variable `$data`
$data = Cpanel::CloudFlare::Helper::__get_json_loadfile_function()->($cf_config_file);
}

sub get_host_api_base {
return {
Expand Down

0 comments on commit 586853d

Please sign in to comment.