revert 8cad3c2d3d
revert Merge pull request 'feat(widgets): add phase 4 validation and accessibility' (#6) from worktree/widgets-phase-4 into main Reviewed-on: #6
This commit is contained in:
@@ -258,13 +258,8 @@ foreach ($pinned_assets as $asset => $hash) {
|
||||
$path = $root . '/assets/widgets/third-party/' . $asset;
|
||||
if (!is_file($path)) {
|
||||
$errors[] = 'Missing pinned widget dependency: ' . $asset;
|
||||
} else {
|
||||
$contents = (string) file_get_contents($path);
|
||||
$raw_hash = hash('sha256', $contents);
|
||||
$lf_hash = hash('sha256', str_replace("\r\n", "\n", $contents));
|
||||
if ($raw_hash !== $hash && $lf_hash !== $hash) {
|
||||
$errors[] = 'Pinned widget dependency changed: ' . $asset;
|
||||
}
|
||||
} elseif (hash_file('sha256', $path) !== $hash) {
|
||||
$errors[] = 'Pinned widget dependency changed: ' . $asset;
|
||||
}
|
||||
}
|
||||
if (!is_file($root . '/assets/widgets/third-party/THIRD_PARTY.md')) {
|
||||
|
||||
Reference in New Issue
Block a user