Skip to content
This repository was archived by the owner on Dec 9, 2024. It is now read-only.

Commit 01f67f7

Browse files
committed
Fix nullability of Menu in onCreateOptionsMenu
... override of LoadingActivity and StaggerActivity. The parameter should be non null, but the current override type is Menu?
1 parent 9045d2b commit 01f67f7

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Motion/app/src/main/java/com/example/android/motion/demo/loading/LoadingActivity.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ class LoadingActivity : AppCompatActivity() {
8787
}
8888
}
8989

90-
override fun onCreateOptionsMenu(menu: Menu?): Boolean {
90+
override fun onCreateOptionsMenu(menu: Menu): Boolean {
9191
menuInflater.inflate(R.menu.loading, menu)
9292
return super.onCreateOptionsMenu(menu)
9393
}

Motion/app/src/main/java/com/example/android/motion/demo/stagger/StaggerActivity.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ class StaggerActivity : AppCompatActivity() {
7777
}
7878
}
7979

80-
override fun onCreateOptionsMenu(menu: Menu?): Boolean {
80+
override fun onCreateOptionsMenu(menu: Menu): Boolean {
8181
menuInflater.inflate(R.menu.stagger, menu)
8282
return super.onCreateOptionsMenu(menu)
8383
}

0 commit comments

Comments
 (0)