Skip to content

Commit

Permalink
docs: fix code sample in readme
Browse files Browse the repository at this point in the history
  • Loading branch information
bryanoltman committed Nov 14, 2024
1 parent ee3f5ec commit 13536da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions shorebird_code_push/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,13 @@ class _MyHomePageState extends State<MyHomePage> {
// Get the current patch number and print it to the console.
// It will be `null` if no patches are installed.
updater.readCurrentPatch().then((currentPatch) {
print('The current patch number is: ${currentPatch.number}');
print('The current patch number is: ${currentPatch?.number}');
});
}
Future<void> _checkForUpdates() async {
// Check whether a new update is available.
final status = await updater.checkForUpdates();
final status = await updater.checkForUpdate();
if (status == UpdateStatus.outdated) {
try {
Expand Down

0 comments on commit 13536da

Please sign in to comment.