<commit_before><?php

namespace App\Http\Controllers;

use App\Template;
use Illuminate\Support\Facades\Redis;


/**
 * Class TemplateController
 * @package App\Http\Controllers
 */
class TemplateController extends Controller
{
    //

    /**
     * @var
     */
    public $user_templates;

    /**
     * @param $hotel_id
     * @return mixed
     */
    public function getTemplates($hotel_id)
    {
         //Redis::del('templates.'.$hotel_id);
        if (Redis::get('templates.' . $hotel_id) === null) {
            $this->user_templates = Template::where('hotel', $hotel_id)->get();
            Redis::set('templates.' . $hotel_id, json_encode($this->user_templates));
        }
        return Redis::get('templates.' . $hotel_id);
    }

}<commit_msg>fixing Vue template gug<commit_after><?php

namespace App\Http\Controllers;

use App\Template;
use Illuminate\Support\Facades\Redis;


/**
 * Class TemplateController
 * @package App\Http\Controllers
 */
class TemplateController extends Controller
{
    //

    /**
     * @var
     */
    public $user_templates;

    /**
     * @param $hotel_id
     * @return mixed
     */
    public function getTemplates($hotel_id)
    {
         Redis::del('templates.'.$hotel_id);
        if (Redis::get('templates.' . $hotel_id) === null) {
            $this->user_templates = Template::where('hotel', $hotel_id)->get();
            Redis::set('templates.' . $hotel_id, json_encode($this->user_templates));
        }
        return Redis::get('templates.' . $hotel_id);
    }

}
{'fraction_non_alphanumeric': 0.15947712418300652, 'fraction_numerical': 0.0, 'mean_word_length': 2.6279620853080567, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, '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': '3737452', 'n_tokens_mistral': 492, 'n_tokens_neox': 494, 'n_words': 81}