Skip to content

Commit

Permalink
Merge branch 'master' of github.com:spatie/laravel-csp
Browse files Browse the repository at this point in the history
  • Loading branch information
freekmurze committed Feb 17, 2018
2 parents c23050d + 7c04c13 commit eee77ed
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/Profiles/Profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ public function reportTo(string $uri): self
{
$this->directives['report-uri'] = [$uri];


$reportToContents = json_encode([
'url' => $uri,
'group-name' => class_basename(static::class),
Expand All @@ -61,7 +60,7 @@ public function shouldBeApplied(Request $request, Response $response): bool

public function addNonceForDirective(string $directive): self
{
return $this->addDirective($directive, "'nonce-" . app('csp-nonce') . "'");
return $this->addDirective($directive, "'nonce-".app('csp-nonce')."'");
}

public function applyTo(Response $response)
Expand Down
4 changes: 2 additions & 2 deletions tests/NonceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ public function calling_the_nonce_function_will_generate_the_same_result()

$this->assertEquals(strlen($nonce), 32);

foreach(range(1,5) as $i) {
foreach (range(1, 5) as $i) {
$this->assertEquals($nonce, cspNonce());
}
}
}
}

0 comments on commit eee77ed

Please sign in to comment.