How to fix "error: cannot find symbol public void onCreate(Bundle savedInstanceState)" when trying to initialize plugin in Capacitor 3

Hi, I upgraded to Capacitor 3 and I am trying to use the community AdMob plugin. To do this I am adding the plugin to the initialization list in as such:

package quiz.manifestation;

import com.getcapacitor.BridgeActivity;

public class MainActivity extends BridgeActivity {
    public void onCreate(Bundle savedInstanceState) {

As it says here in the documentation that you have to register the plugin in onCreate even though is now mostly empty.

When I try to run the app in Android Studio emulator I get the following error:

error: cannot find symbol
public void onCreate(Bundle savedInstanceState) {
symbol: class Bundle
location: class MainActivity

And I’m not quite sure what I am doing wrong. I am using version 3.2.3 of capacitor/android, capacitor/core and capacitor/cli. Thank you for helping me!

Turns out you just have to add “import android.os.Bundle;”. I pulled the trigger a little early on this one.