Commit 70435e8b authored by Matheus Jardim's avatar Matheus Jardim

moved OAuth webviews loading from onResume to onCreate

parent 0fe062dd
...@@ -6,10 +6,12 @@ import android.text.TextUtils; ...@@ -6,10 +6,12 @@ import android.text.TextUtils;
import android.util.Base64; import android.util.Base64;
import android.webkit.JavascriptInterface; import android.webkit.JavascriptInterface;
import android.webkit.WebView; import android.webkit.WebView;
import org.json.JSONException; import org.json.JSONException;
import org.json.JSONObject; import org.json.JSONObject;
import java.nio.charset.Charset; import java.nio.charset.Charset;
import chat.rocket.android.api.MethodCallHelper; import chat.rocket.android.api.MethodCallHelper;
import chat.rocket.android.fragment.AbstractWebViewFragment; import chat.rocket.android.fragment.AbstractWebViewFragment;
import chat.rocket.core.models.LoginServiceConfiguration; import chat.rocket.core.models.LoginServiceConfiguration;
...@@ -61,13 +63,14 @@ public abstract class AbstractOAuthFragment extends AbstractWebViewFragment ...@@ -61,13 +63,14 @@ public abstract class AbstractOAuthFragment extends AbstractWebViewFragment
new RealmLoginServiceConfigurationRepository(hostname), new RealmLoginServiceConfigurationRepository(hostname),
new MethodCallHelper(getContext(), hostname) new MethodCallHelper(getContext(), hostname)
); );
presenter.loadService(getOAuthServiceName());
} }
@Override @Override
public void onResume() { public void onResume() {
super.onResume(); super.onResume();
presenter.bindView(this); presenter.bindView(this);
presenter.loadService(getOAuthServiceName());
} }
@Override @Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment