diff --git a/.idea/modules.xml b/.idea/modules.xml
index b0a1eb4..c241992 100644
--- a/.idea/modules.xml
+++ b/.idea/modules.xml
@@ -2,8 +2,8 @@
-
-
+
+
diff --git a/README.md b/README.md
index 4a680c8..0f621ef 100644
--- a/README.md
+++ b/README.md
@@ -1,6 +1,6 @@
-# nomadcode
+# nomadcode-app
-A new Flutter project.
+nomadcode-app Flutter project.
## Getting Started
diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml
index 67a97f0..b4856ef 100644
--- a/android/app/src/main/AndroidManifest.xml
+++ b/android/app/src/main/AndroidManifest.xml
@@ -6,7 +6,7 @@
diff --git a/android/nomadcode_android.iml b/android/nomadcode_app_android.iml
similarity index 100%
rename from android/nomadcode_android.iml
rename to android/nomadcode_app_android.iml
diff --git a/ios/Runner/Info.plist b/ios/Runner/Info.plist
index 93cd453..0ad5321 100644
--- a/ios/Runner/Info.plist
+++ b/ios/Runner/Info.plist
@@ -7,7 +7,7 @@
CFBundleDevelopmentRegion
$(DEVELOPMENT_LANGUAGE)
CFBundleDisplayName
- Nomadcode
+ nomadcode-app
CFBundleExecutable
$(EXECUTABLE_NAME)
CFBundleIdentifier
@@ -15,7 +15,7 @@
CFBundleInfoDictionaryVersion
6.0
CFBundleName
- nomadcode
+ nomadcode-app
CFBundlePackageType
APPL
CFBundleShortVersionString
diff --git a/lib/main.dart b/lib/main.dart
index 283acbb..ded0e85 100644
--- a/lib/main.dart
+++ b/lib/main.dart
@@ -47,12 +47,12 @@ class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
- title: 'NomadCode',
+ title: 'nomadcode-app',
navigatorKey: _navigatorKey,
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
),
- home: const MyHomePage(title: 'NomadCode'),
+ home: const MyHomePage(title: 'nomadcode-app'),
builder: (context, child) {
_pushService.onNavigateToChannel = (serverUrl, channelId) {
print('[Nav] Navigate to channel: $channelId on $serverUrl');
@@ -113,7 +113,7 @@ class _MyHomePageState extends State {
Widget build(BuildContext context) {
return Scaffold(
body: const Center(
- child: Text('NomadCode'),
+ child: Text('nomadcode-app'),
),
);
}
diff --git a/lib/services/mattermost_auth_service.dart b/lib/services/mattermost_auth_service.dart
index 19ba2f0..46ad383 100644
--- a/lib/services/mattermost_auth_service.dart
+++ b/lib/services/mattermost_auth_service.dart
@@ -1,4 +1,5 @@
import 'dart:convert';
+import 'package:flutter/foundation.dart' show FlutterError;
import 'package:flutter/services.dart' show rootBundle;
import 'package:http/http.dart' as http;
import 'push_notification_service.dart';
@@ -20,6 +21,10 @@ class MattermostAuthService {
/// assets/mattermost_credentials.json 로드 → 로그인 → FCM 등록까지 자동 수행.
Future autoLoginAndRegister() async {
final creds = await _loadCredentials();
+ if (creds == null) {
+ print('[MattermostAuth] Credentials asset not found, skipping auto login.');
+ return;
+ }
_serverUrl = creds['serverUrl']!;
print('[MattermostAuth] Logging in to $_serverUrl ...');
@@ -43,9 +48,13 @@ class MattermostAuthService {
print('[MattermostAuth] Auto login & FCM registration complete.');
}
- Future