Code cleanup
Refactoring (media moved to the separate js file)
Refactoring (random moved to Helpers.js)
Small refactoring
Refactoring
Fixed most of bug produced by refactoring (media files bugs (including loading media))
Removed obsolete code