Moved image storage variable to seperate js file