Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(lints): unnecessary_string_interpolations rule #154

Merged
merged 2 commits into from
Oct 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 0 additions & 2 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,6 @@ linter:

use_key_in_widget_constructors: false

unnecessary_string_interpolations: false

prefer_const_declarations: false

constant_identifier_names: false
Expand Down
2 changes: 1 addition & 1 deletion lib/ui/components/cv_flat_button.dart
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class CVFlatButtonState extends State<CVFlatButton> {
onPressed: dynamicFunction == null
? null
: () => dynamicFunction.call(widget.context),
child: Text('${widget.buttonText}'),
child: Text(widget.buttonText),
);
}
}
7 changes: 4 additions & 3 deletions lib/ui/views/groups/assignment_details_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,7 @@ class _AssignmentDetailsViewState extends State<AssignmentDetailsView> {
),
),
Html(
data: """${_recievedAssignment.attributes.description ?? ''}""",
data: _recievedAssignment.attributes.description ?? '',
style: {
'body': Style(
fontSize: FontSize(18),
Expand Down Expand Up @@ -236,8 +236,9 @@ class _AssignmentDetailsViewState extends State<AssignmentDetailsView> {
child: FadeInImage.memoryNetwork(
fit: BoxFit.cover,
placeholder: kTransparentImage,
image:
'${EnvironmentConfig.CV_API_BASE_URL.substring(0, EnvironmentConfig.CV_API_BASE_URL.length - 7) + _model.focussedProject.attributes.imagePreview.url}',
image: EnvironmentConfig.CV_API_BASE_URL.substring(
0, EnvironmentConfig.CV_API_BASE_URL.length - 7) +
_model.focussedProject.attributes.imagePreview.url,
),
),
)
Expand Down
5 changes: 3 additions & 2 deletions lib/ui/views/projects/components/featured_project_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,9 @@ class _FeaturedProjectCardState extends State<FeaturedProjectCard> {
child: FadeInImage.memoryNetwork(
fit: BoxFit.cover,
placeholder: kTransparentImage,
image:
'${EnvironmentConfig.CV_API_BASE_URL.substring(0, EnvironmentConfig.CV_API_BASE_URL.length - 7) + widget.project.attributes.imagePreview.url}',
image: EnvironmentConfig.CV_API_BASE_URL.substring(
0, EnvironmentConfig.CV_API_BASE_URL.length - 7) +
widget.project.attributes.imagePreview.url,
),
),
),
Expand Down
5 changes: 3 additions & 2 deletions lib/ui/views/projects/components/project_card.dart
Original file line number Diff line number Diff line change
Expand Up @@ -90,8 +90,9 @@ class _ProjectCardState extends State<ProjectCard> {
child: FadeInImage.memoryNetwork(
fit: BoxFit.cover,
placeholder: kTransparentImage,
image:
'${EnvironmentConfig.CV_API_BASE_URL.substring(0, EnvironmentConfig.CV_API_BASE_URL.length - 7) + widget.project.attributes.imagePreview.url}',
image: EnvironmentConfig.CV_API_BASE_URL.substring(
0, EnvironmentConfig.CV_API_BASE_URL.length - 7) +
widget.project.attributes.imagePreview.url,
),
),
),
Expand Down
7 changes: 4 additions & 3 deletions lib/ui/views/projects/project_details_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,9 @@ class _ProjectDetailsViewState extends State<ProjectDetailsView> {
height: 100,
width: 50,
placeholder: kTransparentImage,
image:
'${EnvironmentConfig.CV_API_BASE_URL.substring(0, EnvironmentConfig.CV_API_BASE_URL.length - 7) + _recievedProject.attributes.imagePreview.url}',
image: EnvironmentConfig.CV_API_BASE_URL.substring(
0, EnvironmentConfig.CV_API_BASE_URL.length - 7) +
_recievedProject.attributes.imagePreview.url,
),
),
Material(
Expand Down Expand Up @@ -229,7 +230,7 @@ class _ProjectDetailsViewState extends State<ProjectDetailsView> {
),
),
Html(
data: """${_recievedProject.attributes.description ?? ''}""",
data: _recievedProject.attributes.description ?? '',
style: {'body': Style(fontSize: FontSize(18))},
)
],
Expand Down
5 changes: 3 additions & 2 deletions lib/ui/views/projects/project_preview_fullscreen_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,9 @@ class ProjectPreviewFullScreen extends StatelessWidget {
height: 100,
width: 50,
placeholder: kTransparentImage,
image:
'${EnvironmentConfig.CV_API_BASE_URL.substring(0, EnvironmentConfig.CV_API_BASE_URL.length - 7) + project.attributes.imagePreview.url}',
image: EnvironmentConfig.CV_API_BASE_URL.substring(
0, EnvironmentConfig.CV_API_BASE_URL.length - 7) +
project.attributes.imagePreview.url,
),
),
),
Expand Down