call publish analytics event for reposts

This commit is contained in:
Sean Yesmunt 2020-02-23 20:24:09 -05:00
parent 92eefb604a
commit 0edea00943
5 changed files with 11 additions and 6 deletions

View file

@ -131,7 +131,7 @@
"imagesloaded": "^4.1.4",
"json-loader": "^0.5.4",
"lbry-format": "https://github.com/lbryio/lbry-format.git",
"lbry-redux": "lbryio/lbry-redux#b4fbc212ca6008ec05c31116182bf6dfa7a1cbcb",
"lbry-redux": "lbryio/lbry-redux#6f9ee589a7834851b2fc9d97f807fbc0a0dd6451",
"lbryinc": "lbryio/lbryinc#6a59102c52673502569d2c43bd4ee58c315fb2e4",
"lint-staged": "^7.0.2",
"localforage": "^1.7.1",

View file

@ -982,5 +982,7 @@
"Do you agree to the %terms%?": "Do you agree to the %terms%?",
"While we respect the desire for maximally private usage, please note that choosing this option hurts the ability for creators to understand how their content is performing.": "While we respect the desire for maximally private usage, please note that choosing this option hurts the ability for creators to understand how their content is performing.",
"A copy of your wallet is synced to lbry.tv": "A copy of your wallet is synced to lbry.tv",
"Internal sharing is required while signed in.": "Internal sharing is required while signed in."
"Internal sharing is required while signed in.": "Internal sharing is required while signed in.",
"Your wallet is not currently synced with lbry.tv. You are in control of backing up your wallet.": "Your wallet is not currently synced with lbry.tv. You are in control of backing up your wallet.",
"FINAL WARNING: This action is permanent and cannot be undone.": "FINAL WARNING: This action is permanent and cannot be undone."
}

View file

@ -160,6 +160,7 @@ const analytics: Analytics = {
if (channelClaimId) {
params['channel_claim_id'] = channelClaimId;
}
Lbryio.call('event', 'publish', params);
}
},

View file

@ -11,6 +11,7 @@ import { FormField } from 'component/common/form';
import { parseURI, isNameValid, creditsToString } from 'lbry-redux';
import usePersistedState from 'effects/use-persisted-state';
import I18nMessage from 'component/i18nMessage';
import analytics from 'analytics';
type Props = {
doHideModal: () => void,
@ -105,7 +106,8 @@ function ModalRepost(props: Props) {
bid: creditsToString(repostBid),
channel_id: channelToRepostTo.claim_id,
claim_id: contentClaimId,
}).then(() => {
}).then((repostClaim: StreamClaim) => {
analytics.apiLogPublish(repostClaim);
doHideModal();
doToast({ message: __('Woohoo! Sucessfully reposted this claim.') });
});

View file

@ -7174,9 +7174,9 @@ lazy-val@^1.0.4:
yargs "^13.2.2"
zstd-codec "^0.1.1"
lbry-redux@lbryio/lbry-redux#b4fbc212ca6008ec05c31116182bf6dfa7a1cbcb:
lbry-redux@lbryio/lbry-redux#6f9ee589a7834851b2fc9d97f807fbc0a0dd6451:
version "0.0.1"
resolved "https://codeload.github.com/lbryio/lbry-redux/tar.gz/b4fbc212ca6008ec05c31116182bf6dfa7a1cbcb"
resolved "https://codeload.github.com/lbryio/lbry-redux/tar.gz/6f9ee589a7834851b2fc9d97f807fbc0a0dd6451"
dependencies:
proxy-polyfill "0.1.6"
reselect "^3.0.0"