Skip to content

Commit

Permalink
chore: Bump actions/checkout from 3 to 4 in the github_actions group (#…
Browse files Browse the repository at this point in the history
…220)

* Bump actions/checkout from 3 to 4 in the github_actions group

Bumps the github_actions group with 1 update: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 3 to 4
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: github_actions
...

Signed-off-by: dependabot[bot] <[email protected]>

* fix analyze issues

---------

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Tobias Busch <[email protected]>
  • Loading branch information
dependabot[bot] and brim-borium authored Oct 3, 2024
1 parent a6cac31 commit 555f2de
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 13 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2
with:
channel: 'stable'
Expand All @@ -25,7 +25,7 @@ jobs:
pana:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2

- name: Install Dependencies
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
pana:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- uses: subosito/flutter-action@v2

- name: Install Dependencies
Expand Down
21 changes: 12 additions & 9 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ class HomeState extends State<Home> {
lineLength: 120, // width of the output
colors: true, // Colorful log messages
printEmojis: true, // Print an emoji for each log message
printTime: true,
),
);

Expand Down Expand Up @@ -767,21 +766,25 @@ class HomeState extends State<Home> {

Future<void> checkIfAppIsActive(BuildContext context) async {
try {
await SpotifySdk.isSpotifyAppActive.then((isActive) {
final snackBar = SnackBar(
content: Text(isActive
? 'Spotify app connection is active (currently playing)'
: 'Spotify app connection is not active (currently not playing)'));

ScaffoldMessenger.of(context).showSnackBar(snackBar);
});
final isActive = await SpotifySdk.isSpotifyAppActive;
_showSnackBar(isActive);
} on PlatformException catch (e) {
setStatus(e.code, message: e.message);
} on MissingPluginException {
setStatus('not implemented');
}
}

void _showSnackBar(bool isActive) {
final snackBar = SnackBar(
content: Text(isActive
? 'Spotify app connection is active (currently playing)'
: 'Spotify app connection is not active (currently not playing)'),
);

ScaffoldMessenger.of(context).showSnackBar(snackBar);
}

void setStatus(String code, {String? message}) {
var text = message ?? '';
_logger.i('$code$text');
Expand Down
2 changes: 1 addition & 1 deletion lib/spotify_sdk_web.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
@JS()
library spotify_sdk_web;
library;

import 'dart:async';
import 'dart:convert';
Expand Down

0 comments on commit 555f2de

Please sign in to comment.