segment-integrations / analytics.js-integration-visual-website-optimizer

The Visual Website Optimizer analytics.js integration.
https://segment.com/docs/integrations/visual-website-optimizer/
MIT License
0 stars 2 forks source link

Adding check for exp to be ready and preview #8

Closed hemkaran closed 7 years ago

hemkaran commented 7 years ago

Hi,

Segment is doing wrong tracking as it not checking for experiment to be ready. Also, it is sending data in VWO preview mode also.

WesleyDRobinson commented 7 years ago

👁 @hankim813 @tsholmes for review

hankim813 commented 7 years ago

@hemkaran thanks for the PR! Could you add a unit test for the new if guard?

Also looks like circle failed due to lint errors

codecov-io commented 7 years ago

Codecov Report

Merging #8 into master will not change coverage. The diff coverage is 100%.

Impacted file tree graph

@@          Coverage Diff          @@
##           master     #8   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files           1      1           
  Lines          54     56    +2     
=====================================
+ Hits           54     56    +2
Impacted Files Coverage Δ
lib/index.js 100% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update a44fb9e...f06c626. Read the comment docs.

hemkaran commented 7 years ago

@hankim813 Can you please review now?

hemkaran commented 7 years ago

@hankim813 Can you please release it? One VWO client is waiting for the fix.

hankim813 commented 7 years ago

@hemkaran deployed! thanks for the PR!

hemkaran commented 7 years ago

@hankim813 Thanks. Checked it, working perfectly fine.