Skip to content

NullPointerException when invoking io.flutter.plugins.videoplayer.VideoPlayer.seekTo(int)' on a null object reference, null, null)) #89259

@angelorobo

Description

@angelorobo

Steps to Reproduce

Before 2.0 Flutter, the video player will automatically play a video in our app when the video is clicked to play.
After upgrading to 2.0+ Flutter with null safety, we start getting this error and the video has to be manually paused and resumed before the

Expected results:
A video can automatically play and there is no NullPointerException thrown when calling VideoPlayer.seekTo.

Actual results:
A null pointer exception when calling VideoPlayer.seekTo would cause the video to pause. We have to manually pause and resume to make sure the video can play automatically.

Logs

PlatformException (PlatformException(NullPointerException, java.lang.NullPointerException: Attempt to invoke virtual method 'void io.flutter.plugins.videoplayer.VideoPlayer.seekTo(int)' on a null object reference, null, null))

Metadata

Metadata

Assignees

No one assigned

    Labels

    r: fixedIssue is closed as already fixed in a newer version

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions