From 061599f42ed3c93ef9354112e4761e5967e45376 Mon Sep 17 00:00:00 2001
From: OSBotify <76178356+OSBotify@users.noreply.github.com>
Date: Mon, 20 Sep 2021 12:10:45 -0700
Subject: [PATCH 1/2] Merge pull request #5361 from
Expensify/version-BUILD-499c65aa84660bc78b37fc080c2bb7dc244c95b6
(cherry picked from commit 0a3da2e0bebf5105ea60a36cc453d6a1a9c312bf)
---
android/app/build.gradle | 4 ++--
ios/NewExpensify/Info.plist | 2 +-
ios/NewExpensifyTests/Info.plist | 2 +-
package-lock.json | 2 +-
package.json | 2 +-
5 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/android/app/build.gradle b/android/app/build.gradle
index b801aae12e5d..ed58d5acecea 100644
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -150,8 +150,8 @@ android {
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion rootProject.ext.targetSdkVersion
multiDexEnabled rootProject.ext.multiDexEnabled
- versionCode 1001009903
- versionName "1.0.99-3"
+ versionCode 1001009904
+ versionName "1.0.99-4"
}
splits {
abi {
diff --git a/ios/NewExpensify/Info.plist b/ios/NewExpensify/Info.plist
index 5d5138ebb093..75503044d5f3 100644
--- a/ios/NewExpensify/Info.plist
+++ b/ios/NewExpensify/Info.plist
@@ -31,7 +31,7 @@
CFBundleVersion
- 1.0.99.3
+ 1.0.99.4
ITSAppUsesNonExemptEncryption
LSApplicationQueriesSchemes
diff --git a/ios/NewExpensifyTests/Info.plist b/ios/NewExpensifyTests/Info.plist
index 49fbfbcb7ce7..e676c56b3ff0 100644
--- a/ios/NewExpensifyTests/Info.plist
+++ b/ios/NewExpensifyTests/Info.plist
@@ -19,6 +19,6 @@
CFBundleSignature
????
CFBundleVersion
- 1.0.99.3
+ 1.0.99.4
diff --git a/package-lock.json b/package-lock.json
index d8d55eb7aaaa..d25fd0b610e0 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "new.expensify",
- "version": "1.0.99-3",
+ "version": "1.0.99-4",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
diff --git a/package.json b/package.json
index 82ae48be97e0..676f51f94894 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "new.expensify",
- "version": "1.0.99-3",
+ "version": "1.0.99-4",
"author": "Expensify, Inc.",
"homepage": "https://new.expensify.com",
"description": "New Expensify is the next generation of Expensify: a reimagination of payments based atop a foundation of chat.",
From 790f8040a216b0d4696857ec1a29828cf322cb9a Mon Sep 17 00:00:00 2001
From: Joe Gambino
Date: Mon, 20 Sep 2021 12:08:28 -0700
Subject: [PATCH 2/2] Merge pull request #5360 from
Expensify/revert-5244-beaman-skipShowingCreateForNewUsersIfHasWorkspace
Revert "Skip showing create for new users if user already has a workspace"
(cherry picked from commit 499c65aa84660bc78b37fc080c2bb7dc244c95b6)
---
src/pages/home/sidebar/SidebarScreen.js | 46 +++++--------------------
1 file changed, 9 insertions(+), 37 deletions(-)
diff --git a/src/pages/home/sidebar/SidebarScreen.js b/src/pages/home/sidebar/SidebarScreen.js
index d1d25b47ed4e..6201f049a1eb 100755
--- a/src/pages/home/sidebar/SidebarScreen.js
+++ b/src/pages/home/sidebar/SidebarScreen.js
@@ -2,7 +2,6 @@ import React, {Component} from 'react';
import {View} from 'react-native';
import {withOnyx} from 'react-native-onyx';
import PropTypes from 'prop-types';
-import _ from 'underscore';
import styles from '../../../styles/styles';
import SidebarLinks from './SidebarLinks';
import PopoverMenu from '../../../components/PopoverMenu';
@@ -29,32 +28,17 @@ import Performance from '../../../libs/Performance';
import NameValuePair from '../../../libs/actions/NameValuePair';
const propTypes = {
- /* Onyx Props */
-
- /** Beta features list */
+ /* Beta features list */
betas: PropTypes.arrayOf(PropTypes.string).isRequired,
- /** Flag for new users used to open the Global Create menu on first load */
+ /* Flag for new users used to open the Global Create menu on first load */
isFirstTimeNewExpensifyUser: PropTypes.bool.isRequired,
- /** The list of this user's policies */
- policies: PropTypes.objectOf(PropTypes.shape({
- /** The type of the policy */
- type: PropTypes.string,
-
- /** The user's role in the policy */
- role: PropTypes.string,
- })),
-
...windowDimensionsPropTypes,
...withLocalizePropTypes,
};
-const defaultProps = {
- policies: {},
-};
-
class SidebarScreen extends Component {
constructor(props) {
super(props);
@@ -74,21 +58,13 @@ class SidebarScreen extends Component {
Timing.start(CONST.TIMING.SIDEBAR_LOADED, true);
if (this.props.isFirstTimeNewExpensifyUser) {
- const hasFreePolicy = _.chain(this.props.policies)
- .some(policy => policy && policy.type === CONST.POLICY.TYPE.FREE && policy.role === CONST.POLICY.ROLE.ADMIN)
- .value();
-
- // If user doesn't have any free policies (workspaces) set up, automatically open create menu
- if (!hasFreePolicy) {
- // For some reason, the menu doesn't open without the timeout
- setTimeout(() => {
- this.toggleCreateMenu();
- }, 200);
- }
-
- // Set the NVP to false so we don't automatically open the menu again
- // Note: this may need to be moved if this NVP is used for anything else later
- NameValuePair.set(CONST.NVP.IS_FIRST_TIME_NEW_EXPENSIFY_USER, false, ONYXKEYS.NVP_IS_FIRST_TIME_NEW_EXPENSIFY_USER);
+ // For some reason, the menu doesn't open without the timeout
+ setTimeout(() => {
+ this.toggleCreateMenu();
+
+ // Set the NVP back to false (this may need to be moved if this NVP is used for anything else later)
+ NameValuePair.set(CONST.NVP.IS_FIRST_TIME_NEW_EXPENSIFY_USER, false, ONYXKEYS.NVP_IS_FIRST_TIME_NEW_EXPENSIFY_USER);
+ }, 200);
}
}
@@ -201,7 +177,6 @@ class SidebarScreen extends Component {
}
SidebarScreen.propTypes = propTypes;
-SidebarScreen.defaultProps = defaultProps;
export default compose(
withLocalize,
withWindowDimensions,
@@ -212,8 +187,5 @@ export default compose(
isFirstTimeNewExpensifyUser: {
key: ONYXKEYS.NVP_IS_FIRST_TIME_NEW_EXPENSIFY_USER,
},
- policies: {
- key: ONYXKEYS.COLLECTION.POLICY,
- },
}),
)(SidebarScreen);