TypeError: undefined is not a function
kenjikl opened this issue · comments
I got this problem:
Init youtube api youtube.js:11
TypeError: undefined is not a function
at isYoutube (fvideogular/youtube/youtube.js:115:40)
at onSourceChange (videogular/youtube/youtube.js:119:33)
at Object.fn (videogular/youtube/youtube.js:132:33)
at k.$digest (https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:109:424)
at k.$apply (https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:112:398)
at https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:18:270
at Object.d as invoke
at c (https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:18:178)
at fc (https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:18:387)
at Xc (https://ajax.googleapis.com/ajax/libs/angularjs/1.2.26/angular.min.js:17:415)
I think you using not correct, please read README before
This is happening because of setting src = $sce.trustAsResourceUrl(<some_URL>) for the URLs that aren't YouTube URLs. I'll create a PR to handle...
Please, see recommended workaround in #21