wp-cli/wp-cli — pull request #1269 by trepmal (2014-07-01 18:47:43+00:00)
Title: trim commas on tables list in wp db export

In running `wp db export --tables=$(wp db tables --url=local.dev/msstable/feta --scope=blog | tr '\n' ',')` the list of tables passed looks like `wp_4_posts,wp_4_comments,wp_4_links,wp_4_options,wp_4_postmeta,wp_4_terms,wp_4_term_taxonomy,wp_4_term_relationships,wp_4_commentmeta,`

When the list is later explode()d, the trailing comma causes there to be an empty element in the array, and on export an extra table gets included (whatever is first alphabetically).