[PR #241] [CLOSED] fix(gh issue): null check error #1213

Closed
opened 2026-04-16 02:32:23 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/pd4d10/git-touch/pull/241
Author: @shreyas1599
Created: 6/7/2021
Status: Closed

Base: mainHead: null-check-fix


📝 Commits (2)

📊 Changes

11 files changed (+58 additions, -46 deletions)

View changed files

📝 lib/router.dart (+28 -20)
📝 lib/screens/ge_search.dart (+1 -1)
📝 lib/screens/gh_events.dart (+2 -1)
📝 lib/screens/gh_issue.dart (+11 -12)
📝 lib/screens/gh_repo.dart (+4 -4)
📝 lib/screens/gh_search.dart (+1 -1)
📝 lib/screens/gh_user.dart (+2 -1)
📝 lib/screens/gl_issue.dart (+2 -1)
📝 lib/screens/gl_search.dart (+1 -1)
📝 lib/widgets/release_item.dart (+2 -2)
📝 lib/widgets/timeline_item.dart (+4 -2)

📄 Description

  • null check error in gh_issue
  • a couple of lint errors were auto-fixed
  • fixed the following messages
  String get _keyword => _controller!.text?.trim() ?? '';
                                      ^
lib/screens/gh_repo.dart:273:54: Warning: Operand of null-aware operation '?.' has type 'GRepoCommit_history' which excludes null.
 - 'GRepoCommit_history' is from 'package:git_touch/graphql/github.data.gql.dart' ('lib/graphql/github.data.gql.dart').
                        ((ref.target as GRepoCommit).history?.totalCount ?? 0)
                                                     ^
lib/screens/gl_search.dart:29:39: Warning: Operand of null-aware operation '?.' has type 'String' which excludes null.
  String get _keyword => _controller!.text?.trim() ?? '';
                                      ^
lib/screens/gh_search.dart:28:39: Warning: Operand of null-aware operation '?.' has type 'String' which excludes null.
  String get _keyword => _controller!.text?.trim() ?? '';

image


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/pd4d10/git-touch/pull/241 **Author:** [@shreyas1599](https://github.com/shreyas1599) **Created:** 6/7/2021 **Status:** ❌ Closed **Base:** `main` ← **Head:** `null-check-fix` --- ### 📝 Commits (2) - [`1fa3cf2`](https://github.com/pd4d10/git-touch/commit/1fa3cf231df39d61eba0a7cd8105a2fa0933e793) fix(gh issue): null check error - [`91d57a5`](https://github.com/pd4d10/git-touch/commit/91d57a55665e62e20c4c6dee1288f9da0e323439) fix: lint errors ### 📊 Changes **11 files changed** (+58 additions, -46 deletions) <details> <summary>View changed files</summary> 📝 `lib/router.dart` (+28 -20) 📝 `lib/screens/ge_search.dart` (+1 -1) 📝 `lib/screens/gh_events.dart` (+2 -1) 📝 `lib/screens/gh_issue.dart` (+11 -12) 📝 `lib/screens/gh_repo.dart` (+4 -4) 📝 `lib/screens/gh_search.dart` (+1 -1) 📝 `lib/screens/gh_user.dart` (+2 -1) 📝 `lib/screens/gl_issue.dart` (+2 -1) 📝 `lib/screens/gl_search.dart` (+1 -1) 📝 `lib/widgets/release_item.dart` (+2 -2) 📝 `lib/widgets/timeline_item.dart` (+4 -2) </details> ### 📄 Description - null check error in gh_issue - a couple of lint errors were auto-fixed - fixed the following messages ```lib/screens/ge_search.dart:28:39: Warning: Operand of null-aware operation '?.' has type 'String' which excludes null. String get _keyword => _controller!.text?.trim() ?? ''; ^ lib/screens/gh_repo.dart:273:54: Warning: Operand of null-aware operation '?.' has type 'GRepoCommit_history' which excludes null. - 'GRepoCommit_history' is from 'package:git_touch/graphql/github.data.gql.dart' ('lib/graphql/github.data.gql.dart'). ((ref.target as GRepoCommit).history?.totalCount ?? 0) ^ lib/screens/gl_search.dart:29:39: Warning: Operand of null-aware operation '?.' has type 'String' which excludes null. String get _keyword => _controller!.text?.trim() ?? ''; ^ lib/screens/gh_search.dart:28:39: Warning: Operand of null-aware operation '?.' has type 'String' which excludes null. String get _keyword => _controller!.text?.trim() ?? ''; ``` ![image](https://user-images.githubusercontent.com/28999492/121031468-fe12db00-c7c7-11eb-9036-e981bbed1660.png) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-16 02:32:23 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/git-touch#1213