Skip to content

Commit

Permalink
Don’t report video-playback-size if not defined
Browse files Browse the repository at this point in the history
  • Loading branch information
figureone committed Apr 26, 2018
1 parent 035d23a commit 3707be2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scripts/x-api.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ H5P.VideoXAPI = (function ($) {
// Variables used in compiling xAPI results.

var screenSize = screen.width + 'x' + screen.height;
var playbackSize = (width !== undefined && width !== '') ? width + 'x' + height : 'undetermined';
var playbackSize = (width !== undefined && width !== '') ? width + 'x' + height : undefined;
var playbackRate = rate;
var userAgent = navigator.userAgent;
var isFullscreen = Document.fullscreenElement !== null || document.mozFullScreen || document.webkitIsFullScreen || false;
Expand Down
5 changes: 3 additions & 2 deletions scripts/youtube.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,9 @@ H5P.VideoYouTube = (function ($) {
*/
var getWidthOrHeight = function (returnType) {
var quality = self.getQuality();
var width = '';
var height = '';
var width;
var height;

switch (quality) {
case 'small':
width = '320';
Expand Down

0 comments on commit 3707be2

Please sign in to comment.