Skip to content

Commit

Permalink
Fixes #3512: While adding card in the empty list, the card is duplica…
Browse files Browse the repository at this point in the history
…ted issue fixed
  • Loading branch information
saravanan477 committed Nov 27, 2019
1 parent fb1d38d commit 70bbb9c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 2 additions & 1 deletion build/beautifier.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ function __beautify_recursive($dir)
$path = $dir . DIRECTORY_SEPARATOR . $readdir;
// @todo need to handle dynamically
if (is_dir($path) && !in_array($readdir, array(
'vendors'
'vendors',
'vendor'
))) {
$this->__beautify_recursive($path);
}
Expand Down
5 changes: 4 additions & 1 deletion client/js/views/list_view.js
Original file line number Diff line number Diff line change
Expand Up @@ -1481,7 +1481,10 @@ App.ListView = Backbone.View.extend({
list_id: parseInt(self.model.id)
});
if (filtered_cards.length === 1 || self.model.board.cards.length === 0) {
$('#js-card-listing-' + e.attributes.list_id).append(view.render().el);
var existing_card_id = $('#js-card-listing-' + e.attributes.list_id).find('.js-show-modal-card-view:first').data('card_id');
if (existing_card_id !== parseInt(e.attributes.id)) {
$('#js-card-listing-' + e.attributes.list_id).append(view.render().el);
}
} else {
self.model.cards.reset(filtered_cards);
if (sort_by !== null && sort_direction !== null) {
Expand Down

0 comments on commit 70bbb9c

Please sign in to comment.