Skip to content

Commit

Permalink
fixed some bugs with api key
Browse files Browse the repository at this point in the history
  • Loading branch information
wallenium committed Dec 9, 2018
1 parent c6ab511 commit 58345fb
Show file tree
Hide file tree
Showing 5 changed files with 131 additions and 126 deletions.
6 changes: 3 additions & 3 deletions admin/manage_settings.php
Expand Up @@ -959,7 +959,7 @@ public function display(){

// The importer settings
if($this->game->get_importAuth('a_members_man', 'guild_import')){
if(($this->game->get_importers('guild_imp_rsn') && $this->config->get('servername') == '') || !$this->game->get_require_apikey()){
if(($this->game->get_importers('guild_imp_rsn') && $this->config->get('servername') == '') || $this->game->get_apikeyfield_requiered_and_empty()){
$gimport_out = '<input type="button" name="add" value="'.$this->user->lang('uc_bttn_import').'" disabled="disabled" />';
}else{
$gimport_out = '<input type="button" name="add" value="'.$this->user->lang('uc_bttn_import').'" class="mainoption" onclick="javascript:GuildImport()" />';
Expand All @@ -972,7 +972,7 @@ public function display(){
}

if($this->game->get_importAuth('a_members_man', 'char_mupdate')){
if(($this->game->get_importers('guild_imp_rsn') && $this->config->get('servername') == '') || !$this->game->get_require_apikey()){
if(($this->game->get_importers('guild_imp_rsn') && $this->config->get('servername') == '') || $this->game->get_apikeyfield_requiered_and_empty()){
$cupdate_out = '<input type="button" name="add" value="'.$this->user->lang('uc_bttn_update').'" disabled="disabled" />';
}else{
$cupdate_out = '<input type="button" name="add" value="'.$this->user->lang('uc_bttn_update').'" class="mainoption" onclick="javascript:MassUpdateChars()" />';
Expand Down Expand Up @@ -1059,7 +1059,7 @@ public function display(){
$objStyles->delete_cache(false);
$this->form->reset_fields();
$this->settings_saved = true;
$itt_parserlist = $this->itt->get_parserlist($this->in->get('default_game'));
$itt_parserlist = $this->itt->get_parserlist($this->in->get('default_game'));
$this->config->set($this->itt->changed_prio1($this->in->get('default_game'), key($itt_parserlist)));
$this->display();
redirect('admin/manage_settings.php'.$this->SID); // we need to reload cause of the per-game settings
Expand Down

0 comments on commit 58345fb

Please sign in to comment.