Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Address analyzer issues
  • Loading branch information
stuartmorgan-g committed Jan 26, 2023
commit 4b2368676483cdbfbfedcc3d790feb1a869facbe
1 change: 1 addition & 0 deletions packages/cross_file/lib/src/types/html.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ class XFile extends XFileBase {
///
/// `name` needs to be passed from the outside, since it's only available
/// while handling [html.File]s (when the ObjectUrl is created).
// ignore: use_super_parameters
XFile(
String path, {
String? mimeType,
Expand Down
4 changes: 2 additions & 2 deletions packages/cross_file/lib/src/types/interface.dart
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ class XFile extends XFileBase {
/// `path` of the file doesn't match what the user sees when selecting it
/// (like in web)
XFile(
String path, {
super.path, {
String? mimeType,
String? name,
int? length,
Uint8List? bytes,
DateTime? lastModified,
@visibleForTesting CrossFileTestOverrides? overrides,
}) : super(path) {
}) {
throw UnimplementedError(
'CrossFile is not available in your current platform.');
}
Expand Down
1 change: 1 addition & 0 deletions packages/cross_file/lib/src/types/io.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class XFile extends XFileBase {
/// [bytes] is ignored; the parameter exists only to match the web version of
/// the constructor. To construct a dart:io XFile from bytes, use
/// [XFile.fromData].
// ignore: use_super_parameters
XFile(
String path, {
String? mimeType,
Expand Down
2 changes: 1 addition & 1 deletion packages/cross_file/test/x_file_io_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ void main() {

/// An XFile subclass that tracks reads, for testing purposes.
class TestXFile extends XFile {
TestXFile(String path) : super(path);
TestXFile(super.path);

bool hasBeenRead = false;

Expand Down