diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 06f297c..d561134 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -16,7 +16,7 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Setup PHP uses: shivammathur/setup-php@v2 with: @@ -27,9 +27,9 @@ jobs: run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json" - name: Get composer cache directory id: composer-cache - run: echo "::set-output name=dir::$(composer config cache-files-dir)" + run: echo "dir=$(composer config cache-files-dir)" >> "$GITHUB_OUTPUT" - name: Cache dependencies - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: ${{ steps.composer-cache.outputs.dir }} key: dependencies-${{ matrix.php }}-${{ matrix.stability }}-composer-${{ hashFiles('**/composer.lock') }} diff --git a/src/Services/SlugService.php b/src/Services/SlugService.php index 7e87228..093dae6 100644 --- a/src/Services/SlugService.php +++ b/src/Services/SlugService.php @@ -375,7 +375,9 @@ protected function getExistingSlugs(string $slug, string $attribute, array $conf } // get the list of all matching slugs - $results = $query->select([$attribute, $this->model->getQualifiedKeyName()]) + $results = $query + ->withoutEagerLoads() + ->select([$attribute, $this->model->getQualifiedKeyName()]) ->get() ->toBase();