diff --git a/src/material-table.js b/src/material-table.js index 7d14c3e8..0f3a3bb5 100644 --- a/src/material-table.js +++ b/src/material-table.js @@ -465,9 +465,15 @@ export default class MaterialTable extends React.Component { (a) => a.tableData.id === orderBy ); query.orderDirection = orderDirection; - console.warn( - 'Properties orderBy and orderDirection had been deprecated when remote data, please start using orderByCollection instead' - ); + /** + * THIS WILL NEED TO BE REMOVED EVENTUALLY. + * Warn consumer of deprecated prop. + */ + if (query.orderDirection !== undefined || query.orderBy !== undefined) { + console.warn( + 'Properties orderBy and orderDirection had been deprecated when remote data, please start using orderByCollection instead' + ); + } query.orderByCollection = orderByCollection; this.onQueryChange(query, () => { this.props.onOrderChange &&