Skip to content

Commit 0b1c0e9

Browse files
committed
code quality
1 parent 4a42cc8 commit 0b1c0e9

File tree

3 files changed

+10
-6
lines changed

3 files changed

+10
-6
lines changed

src/Migrations/MigrateMakeCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public function __construct(MigrationCreator $creator, Composer $composer)
2828
public function handle()
2929
{
3030
$name = $this->input->getOption('name');
31-
31+
3232
if ($modelClass = $this->input->getOption('model')) {
3333
if (!class_exists($modelClass)) {
3434
throw new InvalidArgumentException("$modelClass class does not exist!");

src/Searchable.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public function searchableAs()
4545
{
4646
return config(
4747
'scout.sqlout.table_name',
48-
config('scout.prefix').$this->getTable().config('scout.suffix', '_index')
48+
config('scout.prefix') . $this->getTable() . config('scout.suffix', '_index')
4949
);
5050
}
5151
}

tests/SearchTest.php

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ public function test_wheres()
139139
$search = Comment::search('kuku')->whereIn('author', ['toto', 'tutu']);
140140
$this->assertEquals(3, $search->count());
141141
$this->assertEquals(3, $search->get()->count());
142-
142+
143143
$search = Comment::search('kuku')
144144
->whereIn('author', ['toto', 'kiki'])
145145
->where('post_id', 1);
@@ -177,7 +177,9 @@ public function test_forwarded_scope()
177177

178178
public function test_macro_has_priority_over_scope()
179179
{
180-
ScoutBuilder::macro('author', function () { return 'gargamel'; });
180+
ScoutBuilder::macro('author', function () {
181+
return 'gargamel';
182+
});
181183
$this->assertEquals('gargamel', Comment::search('schtroumpf')->author());
182184
}
183185

@@ -244,7 +246,7 @@ public function test_filters()
244246

245247
/**
246248
* @dataProvider stopWordsProvider
247-
*/
249+
*/
248250
public function test_stopwords($config, $content, $expectedIndexedContent)
249251
{
250252
app('config')->set('scout.sqlout.stopwords', $config);
@@ -379,7 +381,9 @@ public function test_paginate()
379381
$this->assertEquals(2, $paginator->currentPage());
380382
$this->assertEquals(
381383
$ids->skip(2)->take(2)->values()->all(),
382-
array_map(function ($item) { return $item->id; }, $paginator->items())
384+
array_map(function ($item) {
385+
return $item->id;
386+
}, $paginator->items())
383387
);
384388
}
385389

0 commit comments

Comments
 (0)