Skip to content

Commit a6d9482

Browse files
authored
Merge branch 'main' into fix-4673
2 parents b78329a + cf0d582 commit a6d9482

File tree

3 files changed

+27
-5
lines changed

3 files changed

+27
-5
lines changed

examples/language/lib/patterns/pattern_types.dart

+2-2
Original file line numberDiff line numberDiff line change
@@ -187,13 +187,13 @@ void miscDeclAnalyzedButNotTested() {
187187
case (:var untyped, :int typed): // ...
188188
}
189189

190-
// Record pattern wih null-check and null-assert subpatterns:
190+
// Record pattern with null-check and null-assert subpatterns:
191191
switch (record) {
192192
case (checked: var checked?, asserted: var asserted!): // ...
193193
case (:var checked?, :var asserted!): // ...
194194
}
195195

196-
// Record pattern wih cast subpattern:
196+
// Record pattern with cast subpattern:
197197
var (untyped: untyped as int, typed: typed as String) = record;
198198
var (:untyped as int, :typed as String) = record;
199199
// #enddocregion record-getter

src/language/pattern-types.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -383,13 +383,13 @@ switch (record) {
383383
case (:var untyped, :int typed): // ...
384384
}
385385
386-
// Record pattern wih null-check and null-assert subpatterns:
386+
// Record pattern with null-check and null-assert subpatterns:
387387
switch (record) {
388388
case (checked: var checked?, asserted: var asserted!): // ...
389389
case (:var checked?, :var asserted!): // ...
390390
}
391391
392-
// Record pattern wih cast subpattern:
392+
// Record pattern with cast subpattern:
393393
var (untyped: untyped as int, typed: typed as String) = record;
394394
var (:untyped as int, :typed as String) = record;
395395
```

src/tools/pub/pubspec.md

+23-1
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ A pubspec can have the following fields:
9696

9797
`ignored_advisories`
9898
: Optional. List of ignored security advisories.
99-
[_Learn more._](/tools/pub/security-advisories)
99+
[_Learn more._](#ignored_advisories)
100100

101101
Pub ignores all other fields.
102102

@@ -449,6 +449,28 @@ Pub.dev requires topics to follow these specifications:
449449
When choosing topics, consider if [existing topics]({{site.pub}}/topics)
450450
are relevant. Tagging with existing topics helps users discover your package.
451451

452+
### Ignored_advisories
453+
454+
If a package has a dependency that is affected by a security advisory,
455+
pub warns about the advisory during dependency resolution.
456+
Package authors can use the `ignored_advisories` field as an allowlist
457+
of triggered advisories that are not relevant for the package.
458+
459+
To suppress the warning about an advisory,
460+
add the advisory identifier to the `ignored_advisories` list.
461+
For example:
462+
463+
```yaml
464+
name: myapp
465+
dependencies:
466+
foo: ^1.0.0
467+
ignored_advisories:
468+
- GHSA-4rgh-jx4f-qfcq
469+
```
470+
471+
For more information, check out
472+
[Security advisories](/tools/pub/security-advisories).
473+
452474
### SDK constraints
453475

454476
A package can indicate which versions of its dependencies it supports, but

0 commit comments

Comments
 (0)