Skip to content

Commit

Permalink
Home loading improvements & bump to 0.8.0
Browse files Browse the repository at this point in the history
  • Loading branch information
micahlt committed Dec 29, 2024
1 parent 0c5441e commit a0c39d6
Show file tree
Hide file tree
Showing 9 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ android {
applicationId "com.micahlindley.offsides"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
versionCode 44
versionName "0.7.10"
versionCode 45
versionName "0.8.0"
}
signingConfigs {
debug {
Expand Down
Binary file modified android/app/release/app-release.apk
Binary file not shown.
Binary file modified android/app/release/baselineProfiles/0/app-release.dm
Binary file not shown.
Binary file modified android/app/release/baselineProfiles/1/app-release.dm
Binary file not shown.
4 changes: 2 additions & 2 deletions android/app/release/output-metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@
"type": "SINGLE",
"filters": [],
"attributes": [],
"versionCode": 44,
"versionName": "0.7.10",
"versionCode": 45,
"versionName": "0.8.0",
"outputFile": "app-release.apk"
}
],
Expand Down
4 changes: 2 additions & 2 deletions docs/latest.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"latestVersion": "0.7.10",
"changelog": "This update attempts to solve an issue that some users were encountering that prevented the app from loading."
"latestVersion": "0.8.0",
"changelog": "This update brings further stability improvements."
}
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "offsides",
"version": "0.7.10",
"version": "0.8.0",
"private": true,
"scripts": {
"android": "react-native run-android",
Expand Down
6 changes: 3 additions & 3 deletions src/screens/HomeScreen.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ function HomeScreen({ navigation, route }) {

React.useEffect(() => {
crashlytics().log('Setting group color');
if (currentGroup.color) {
if (currentGroup?.color) {
const t = createMaterial3Theme(currentGroup.color);
setCustomTheme(colorScheme == 'dark' ? t.dark : t.light);
}
Expand All @@ -85,7 +85,7 @@ function HomeScreen({ navigation, route }) {
updateSortIcon();
if (!loadingPosts) {
InteractionManager.runAfterInteractions(() => {
if (appState.userToken && currentGroup.id) {
if (appState.userToken && currentGroup?.id) {
fetchPosts(true, currentGroup.id);
} else {
console.log('App state is undefined, will load in a second');
Expand Down Expand Up @@ -116,7 +116,7 @@ function HomeScreen({ navigation, route }) {
}
};
const fetchPosts = (refresh, override) => {
if (loadingPosts) return false;
if (loadingPosts || !currentGroup?.id || !postSortMethod) return false;
crashlytics().log(`Fetching posts sorted by ${postSortMethod}`);
setLoadingPosts(true);
try {
Expand Down

0 comments on commit a0c39d6

Please sign in to comment.