remove unnecessary code

This commit is contained in:
Shpuld Shpuldson 2020-07-07 09:08:50 +03:00
parent b4709f93d4
commit f4bdbf7691
2 changed files with 1 additions and 10 deletions

View File

@ -6,7 +6,7 @@ import PollForm from '../poll/poll_form.vue'
import Attachment from '../attachment/attachment.vue' import Attachment from '../attachment/attachment.vue'
import fileTypeService from '../../services/file_type/file_type.service.js' import fileTypeService from '../../services/file_type/file_type.service.js'
import { findOffset } from '../../services/offset_finder/offset_finder.service.js' import { findOffset } from '../../services/offset_finder/offset_finder.service.js'
import { reject, map, uniqBy, debounce } from 'lodash' import { reject, map, uniqBy } from 'lodash'
import suggestor from '../emoji_input/suggestor.js' import suggestor from '../emoji_input/suggestor.js'
import { mapGetters } from 'vuex' import { mapGetters } from 'vuex'
import Checkbox from '../checkbox/checkbox.vue' import Checkbox from '../checkbox/checkbox.vue'
@ -396,14 +396,6 @@ const PostStatusForm = {
dismissScopeNotice () { dismissScopeNotice () {
this.$store.dispatch('setOption', { name: 'hideScopeNotice', value: true }) this.$store.dispatch('setOption', { name: 'hideScopeNotice', value: true })
}, },
debounceSendDescription: debounce(function (id, description) {
statusPoster.setMediaDescription({ store: this.$store, id, description })
}, 500),
updateMediaDescription (fileId, e) {
const description = e.target.value
this.newStatus.mediaDescriptions[fileId] = description
this.debounceSendDescription(fileId, description)
},
setMediaDescription (id) { setMediaDescription (id) {
const description = this.newStatus.mediaDescriptions[id] const description = this.newStatus.mediaDescriptions[id]
if (!description || description.trim() === '') return if (!description || description.trim() === '') return

View File

@ -255,7 +255,6 @@
v-model="newStatus.mediaDescriptions[file.id]" v-model="newStatus.mediaDescriptions[file.id]"
type="text" type="text"
:placeholder="$t('post_status.media_description')" :placeholder="$t('post_status.media_description')"
@blur="setMediaDescription(file.id)"
@keydown.enter.prevent="" @keydown.enter.prevent=""
> >
</div> </div>