Merge pull request #2836 from lbryio/internalApiInDev

allows logView events with internal apis dev
This commit is contained in:
jessopb 2019-09-02 14:13:47 -04:00 committed by GitHub
commit ac700c851a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -8,6 +8,7 @@ import ElectronCookies from '@exponent/electron-cookies';
// @endif
const isProduction = process.env.NODE_ENV === 'production';
const devInternalApis = process.env.LBRY_API_URL;
type Analytics = {
pageView: string => void,
@ -48,7 +49,7 @@ const analytics: Analytics = {
// @endif
},
apiLogView: (uri, outpoint, claimId, timeToStart) => {
if (analyticsEnabled && isProduction) {
if (analyticsEnabled && (isProduction || devInternalApis)) {
const params: {
uri: string,
outpoint: string,