fossasia/loklak_webclient

View on GitHub
iframely/lib/plugins/validators/sync/10_video_hml5.js

Summary

Maintainability
A
0 mins
Test Coverage
module.exports = {

    prepareLink: function(link) {
        // Add 'html5' rel to 'video/*'.
        if (link.type.indexOf('video/') === 0) {

            if (link.rel.indexOf('html5') === -1) {
                link.rel.push('html5');
            }

            if (link.rel.indexOf('player') === -1) {
                link.rel.push('player');
            }
        }
    }
};