<commit_before><?php

class Controller_Admin extends Controller
{
	public function before(){
		//Cookie::delete('user_name');
		$user_name = Cookie::get('user_name');
		$base_url= Uri::base();
	//$user_name="bakutaro02";
		//$user_name="1";
		if(isset($user_name)){
			$user_list_query=DB::select()->from('userinfo');
			$user_list_query->where('user_name','=',$user_name);
			$user_list_result = $user_list_query->execute()->as_array();
			Session::set('money', $user_list_result[0]['money']);
			Session::set('single_post_flg', $user_list_result[0]['single_post_flg']);
			Session::set('single_battle_id', $user_list_result[0]['single_battle_id']);
			Session::set('former_single_battle_id', $user_list_result[0]['former_single_battle_id']);
			Session::set('user_name', $user_list_result[0]['user_name']);
			Session::set('group_vote_flg', $user_list_result[0]['group_vote_flg']);
		}else{
			//$base_url= Uri::base();
			//Response::redirect($base_url."confirmlogin");
		}
	}
		
}
<commit_msg>refacturing<commit_after><?php

class Controller_Admin extends Controller
{
	public function before(){
		$user_name = Cookie::get('user_name');
		$base_url= Uri::base();
		if(isset($user_name)){
			$user_list_query=DB::select()->from('userinfo');
			$user_list_query->where('user_name','=',$user_name);
			$user_list_result = $user_list_query->execute()->as_array();
			Session::set('money', $user_list_result[0]['money']);
			Session::set('single_post_flg', $user_list_result[0]['single_post_flg']);
			Session::set('single_battle_id', $user_list_result[0]['single_battle_id']);
			Session::set('former_single_battle_id', $user_list_result[0]['former_single_battle_id']);
			Session::set('user_name', $user_list_result[0]['user_name']);
			Session::set('group_vote_flg', $user_list_result[0]['group_vote_flg']);
	}
		
}

{'fraction_non_alphanumeric': 0.20352035203520352, 'fraction_numerical': 0.00825082508250825, 'mean_word_length': 8.624338624338625, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4107876', 'n_tokens_mistral': 720, 'n_tokens_neox': 660, 'n_words': 65}