public function toggleOnboarding(array $account = NULL) {

    // No user given, then current user.
    $id = $this->currentUser->id();
    if ($account instanceof User) {
      $id = $account->id();
    }

    $new_value = TRUE;
    if ($this->userData->get('social_tour', $id, 'onboarding_disabled') == TRUE) {
      $new_value = FALSE;
    }

    // Save the value in the user_data.
    $this->setData($new_value);
  }
public function toggleOnboarding(array $account = NULL) {

    // No user given, then current user.
    $id = $this->currentUser->id();
    if ($account instanceof User) {
      $id = $account->id();
    }

    $new_value = TRUE;
    if ($this->userData->get('social_tour', $id, 'onboarding_disabled') == TRUE) {
      $new_value = FALSE;
    }

    // Save the value in the user_data.
    $this->setData($new_value);
  }
public function toggleOnboarding ( array $ account = NULL ) { // No user given, then current user. $ id = $ this -> currentUser -> id ( ) ; if ( $ account instanceof User ) { $ id = $ account -> id ( ) ; } $ new_value = TRUE ; if ( $ this -> userData -> get ( 'social_tour' , $ id , 'onboarding_disabled' ) == TRUE ) { $ new_value = FALSE ; } // Save the value in the user_data. $ this -> setData ( $ new_value ) ; }
Toggle onboarding.

@param array $account
Array containing the account.
Toggle onboarding .