You are here

public function LingotekAccount::__construct in Lingotek Translation 8

Constructor.

Sets default values

File

src/LingotekAccount.php, line 38
Defines LingotekAccount.

Class

LingotekAccount

Namespace

Drupal\lingotek

Code

public function __construct() {
  $this->status = self::UNKNOWN;
  $this->planType = self::UNKNOWN;

  // assume an standard active account
  $current_status = variable_get('lingotek_account_status', self::ACTIVE);
  $current_plan_type = variable_get('lingotek_account_plan_type', 'standard');
  if (isset($current_status) && isset($current_plan_type)) {
    $this
      ->setStatus($current_status);
    $this
      ->setPlanType($current_plan_type);
  }
}