if (file.type && /^video\/.+/.test(file.type)) {
        attachment.video_url = url;
        attachment.video_type = file.type;
        attachment.video_size = file.size;
    }