I'm Alex, I don't know much about flutter, I changed the api url to the url of my website and the app doesn't work, it allows me to register and redirects me to home, but when I exit and try to enter again, I get the message I have done login but it does not enter, and if I close the app and try to open it again it stays loading and does nothing, What I get in the debugging console is this:
E/flutter (19730): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: type 'Null' is not a subtype of type 'String'
E/flutter (19730): #0 LoginService.login
package:qixer/…/auth_services/login_service.dart:74
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #1 SplashService.loginOrGoHome
package:qixer/service/splash_service.dart:56
E/flutter (19730): <asynchronous suspension>
E/flutter (19730):
E/flutter (19730): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: HandshakeException: Connection terminated during handshake
I/flutter (19730): {"users":{"id":1204,"email":"cliente2@gmail.es","user_type":1,"country_id":68,"state":"50","username":"cliente2"},"token":"69|JxR68B0WUGoaVVxauEjyrFXg88prbPUdOievSNcO"}
I/flutter (19730): token is 69|JxR68B0WUGoaVVxauEjyrFXg88prbPUdOievSNcO
E/flutter (19730): #0 _RawSecureSocket._tryFilter (dart:io/secure_socket.dart:1016:15)
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #1 _RawSecureSocket._secureHandshake (dart:io/secure_socket.dart:919:9)
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #2 _RawSecureSocket._tryFilter (dart:io/secure_socket.dart:1040:13)
E/flutter (19730): <asynchronous suspension>
E/flutter (19730):
E/flutter (19730): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Connection closed before full header was received
E/flutter (19730): #0 IOClient.send
package:http/src/io_client.dart:66
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #1 BaseClient._sendUnstreamed
package:http/src/base_client.dart:93
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #2 _withClient
package:http/http.dart:164
E/flutter (19730): <asynchronous suspension>
E/flutter (19730): #3 RtlService.fetchCurrency
package:qixer/service/rtl_service.dart:19
E/flutter (19730): <asynchronous suspension>
E/flutter (19730):
I'm not sure what codes you need to see in order to help me, but if you tell me which file you need to see, I'll look for the code and paste it here, I hope you can help me and thanks!
I just changed the api url in /lib/utils/ to the api url of my website, I expected it to connect to my website without problem, what happened is that when I open the app for the first time and register, everything is fine, I am redirected to the home, but when I closed the session it would not let me enter, although if I skipped the successful login message, when I closed the app and tried to open it again it kept loading the home icon, I tried to clear the data and the cache, it would let me open the app but not login.