Skip to content

Commit

Permalink
Merge branch 'master' into LarsRefsgaard/data-page-null-safety
Browse files Browse the repository at this point in the history
  • Loading branch information
LarsRefsgaard authored Jul 19, 2023
2 parents 1d2dce3 + 34cd96b commit a5e7a19
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions lib/ui/pages/message_details_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class MessageDetailsPage extends StatelessWidget {
subTitle: 'Unknown message',
type: MessageType.announcement,
timestamp: DateTime.now(),
imagePath: './assets/images/kids.png');
image: './assets/images/kids.png');
});

return Scaffold(
Expand All @@ -44,7 +44,7 @@ class MessageDetailsPage extends StatelessWidget {
Flexible(
child: CustomScrollView(
slivers: [
DetailsBanner(message.title!, message.imagePath),
DetailsBanner(message.title!, message.image),
SliverToBoxAdapter(
child: Padding(
padding: const EdgeInsets.symmetric(horizontal: 30),
Expand Down
4 changes: 2 additions & 2 deletions lib/ui/pages/study_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class StudyPageState extends State<StudyPage> {
timeago.setLocaleMessages('da', timeago.DaMessages());
timeago.setLocaleMessages('es', timeago.EsMessages());

Image messageImage = widget.model.getMessageImage(message.imagePath);
Image messageImage = widget.model.getMessageImage(message.image);

return Card(
semanticContainer: true,
Expand All @@ -78,7 +78,7 @@ class StudyPageState extends State<StudyPage> {
mainAxisAlignment: MainAxisAlignment.center,
children: [
Row(children: [
message.imagePath != null
message.image != null
? Expanded(
child: Container(
height: 150.0,
Expand Down
2 changes: 1 addition & 1 deletion lib/view_models/cards/heart_rate_data_model.dart
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class HeartRateCardViewModel extends SerializableViewModel<HourlyHeartRate> {

heartRateEvents?.listen(
(heartRateDataPoint) {
PolarHR? heartRate = heartRateDataPoint.data as PolarHR;
PolarHRSample? heartRate = heartRateDataPoint.data as PolarHRSample;

double hr = heartRate.hr.toDouble();
if (!(hr > 0)) {
Expand Down

0 comments on commit a5e7a19

Please sign in to comment.