<commit_before><?php
namespace TypiCMS\Models;

use App;
use Route;
use Input;
use Mockery;
use Eloquent;

/**
 * @method string order($query)
 * @method string whereHasOnlineTranslation($query)
 * @method string files($query, $all)
 * @method string order($query)
 * @method string withOnlineGalleries($query)
 */
abstract class Base extends Eloquent
{
    /**
     * For testing
     */
    public static function shouldReceive()
    {
        $class = class_basename(get_called_class());
        $repo = 'TypiCMS\\Modules\\'.str_plural($class).'\\Repositories\\'.$class.'Interface';
        $mock = Mockery::mock($repo);

        App::instance($repo, $mock);

        return call_user_func_array(array($mock, 'shouldReceive'), func_get_args());
    }

    /**
     * Get preview uri
     *
     * @return null|string string or null
     */
    public function previewUri()
    {
        if (! $this->id) {
            return null;<commit_msg>psr2 error test<commit_after><?php
namespace TypiCMS\Models;

use App;
use Route;
use Input;
use Mockery;
use Eloquent;

/**
 * @method string order($query)
 * @method string whereHasOnlineTranslation($query)
 * @method string files($query, $all)
 * @method string order($query)
 * @method string withOnlineGalleries($query)
 */
abstract class Base extends Eloquent {
    /**
     * For testing
     */
    public static function shouldReceive()
    {
        $class = class_basename(get_called_class());
        $repo = 'TypiCMS\\Modules\\'.str_plural($class).'\\Repositories\\'.$class.'Interface';
        $mock = Mockery::mock($repo);

        App::instance($repo, $mock);

        return call_user_func_array(array($mock, 'shouldReceive'), func_get_args());
    }

    /**
     * Get preview uri
     *
     * @return null|string string or null
     */
    public function previewUri()
    {
        if (! $this->id) {
            return null;
{'fraction_non_alphanumeric': 0.14376321353065538, 'fraction_numerical': 0.0005285412262156448, 'mean_word_length': 2.9355509355509355, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '6482060', 'n_tokens_mistral': 590, 'n_tokens_neox': 570, 'n_words': 135}