File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
samplejava/src/main/java/com/example/chattutorial
samplekotlin/src/main/java/com/example/chattutorial Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 1111
1212import io .getstream .chat .android .client .ChatClient ;
1313import io .getstream .chat .android .client .api .models .FilterObject ;
14+ import io .getstream .chat .android .client .logger .ChatLogLevel ;
1415import io .getstream .chat .android .client .models .Filters ;
1516import io .getstream .chat .android .client .models .User ;
1617import io .getstream .chat .android .livedata .ChatDomain ;
@@ -30,7 +31,9 @@ protected void onCreate(@Nullable Bundle savedInstanceState) {
3031 setContentView (binding .getRoot ());
3132
3233 // Step 1 - Set up the client for API calls and the domain for offline storage
33- ChatClient client = new ChatClient .Builder ("b67pax5b2wdq" , getApplicationContext ()).build ();
34+ ChatClient client = new ChatClient .Builder ("b67pax5b2wdq" , getApplicationContext ())
35+ .logLevel (ChatLogLevel .ALL ) // Set to NOTHING in prod
36+ .build ();
3437 new ChatDomain .Builder (client , getApplicationContext ()).build ();
3538
3639 // Step 2 - Authenticate and connect the user
Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import androidx.activity.viewModels
55import androidx.appcompat.app.AppCompatActivity
66import com.example.chattutorial.databinding.ActivityMainBinding
77import io.getstream.chat.android.client.ChatClient
8+ import io.getstream.chat.android.client.logger.ChatLogLevel
89import io.getstream.chat.android.client.models.Filters
910import io.getstream.chat.android.client.models.User
1011import io.getstream.chat.android.livedata.ChatDomain
@@ -24,7 +25,9 @@ class MainActivity : AppCompatActivity() {
2425 setContentView(binding.root)
2526
2627 // Step 1 - Set up the client for API calls and the domain for offline storage
27- val client = ChatClient .Builder (" b67pax5b2wdq" , applicationContext).build()
28+ val client = ChatClient .Builder (" b67pax5b2wdq" , applicationContext)
29+ .logLevel(ChatLogLevel .ALL ) // Set to NOTHING in prod
30+ .build()
2831 ChatDomain .Builder (client, applicationContext).build()
2932
3033 // Step 2 - Authenticate and connect the user
You can’t perform that action at this time.
0 commit comments