mirror of
https://github.com/LBRYFoundation/lbry-android.git
synced 2025-08-28 16:01:27 +00:00
updates to handle the updated notification implementation in lbry-redux
This commit is contained in:
parent
eb4995da86
commit
f1ee7586f9
2 changed files with 12 additions and 15 deletions
11
app/package-lock.json
generated
11
app/package-lock.json
generated
|
@ -3993,8 +3993,17 @@
|
||||||
"version": "github:lbryio/lbryinc#f2fff2a331578aef84eb77c108f976967afc50e0",
|
"version": "github:lbryio/lbryinc#f2fff2a331578aef84eb77c108f976967afc50e0",
|
||||||
"from": "github:lbryio/lbryinc",
|
"from": "github:lbryio/lbryinc",
|
||||||
"requires": {
|
"requires": {
|
||||||
"lbry-redux": "github:lbryio/lbry-redux#31f7afa8a37f5741dac01fc1ecdf153f3bed95dc",
|
|
||||||
"reselect": "^3.0.0"
|
"reselect": "^3.0.0"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"lbry-redux": {
|
||||||
|
"version": "github:lbryio/lbry-redux#31f7afa8a37f5741dac01fc1ecdf153f3bed95dc",
|
||||||
|
"from": "github:lbryio/lbry-redux#31f7afa8a37f5741dac01fc1ecdf153f3bed95dc",
|
||||||
|
"requires": {
|
||||||
|
"proxy-polyfill": "0.1.6",
|
||||||
|
"reselect": "^3.0.0"
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"lcid": {
|
"lcid": {
|
||||||
|
|
|
@ -33,7 +33,7 @@ import {
|
||||||
ToastAndroid
|
ToastAndroid
|
||||||
} from 'react-native';
|
} from 'react-native';
|
||||||
import { doDeleteCompleteBlobs } from '../redux/actions/file';
|
import { doDeleteCompleteBlobs } from '../redux/actions/file';
|
||||||
import { SETTINGS, doHideNotification, doToast, selectToast } from 'lbry-redux';
|
import { SETTINGS, doDismissToast, doToast, selectToast } from 'lbry-redux';
|
||||||
import {
|
import {
|
||||||
doUserEmailVerify,
|
doUserEmailVerify,
|
||||||
doUserEmailVerifyFailure,
|
doUserEmailVerifyFailure,
|
||||||
|
@ -250,18 +250,6 @@ class AppWithNavigationState extends React.Component {
|
||||||
if (toast) {
|
if (toast) {
|
||||||
const { message } = toast;
|
const { message } = toast;
|
||||||
let currentDisplayType;
|
let currentDisplayType;
|
||||||
if (displayType && displayType.length) {
|
|
||||||
for (let i = 0; i < displayType.length; i++) {
|
|
||||||
const type = displayType[i];
|
|
||||||
if (AppWithNavigationState.supportedDisplayTypes.indexOf(type) > -1) {
|
|
||||||
currentDisplayType = type;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (AppWithNavigationState.supportedDisplayTypes.indexOf(displayType) > -1) {
|
|
||||||
currentDisplayType = displayType;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!currentDisplayType && message) {
|
if (!currentDisplayType && message) {
|
||||||
// default to toast if no display type set and there is a message specified
|
// default to toast if no display type set and there is a message specified
|
||||||
currentDisplayType = 'toast';
|
currentDisplayType = 'toast';
|
||||||
|
@ -271,7 +259,7 @@ class AppWithNavigationState extends React.Component {
|
||||||
ToastAndroid.show(message, ToastAndroid.LONG);
|
ToastAndroid.show(message, ToastAndroid.LONG);
|
||||||
}
|
}
|
||||||
|
|
||||||
dispatch(doHideNotification());
|
dispatch(doDismissToast());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (user &&
|
if (user &&
|
||||||
|
|
Loading…
Add table
Reference in a new issue