Fixed masonry.js bug