Merge branch 'master' into mx

mx
Letícia Camara 2018-10-13 02:19:53 -03:00
commit 80d200f5c8
3 changed files with 5 additions and 1 deletions

View File

@ -144,6 +144,7 @@ class EnhancedTable extends Component {
// If query is empty or undefined // If query is empty or undefined
if (!query) { if (!query) {
this.setState({searchQuery: ''}); this.setState({searchQuery: ''});
this.props.onSearchChange(this.props.data);
return; return;
} }
// Update the search field as soon as the character is typed // Update the search field as soon as the character is typed

View File

@ -124,7 +124,8 @@ class AmbassadorsPage extends Component {
query: { query: {
$sort: { account: 1 }, $sort: { account: 1 },
$limit: limit, $limit: limit,
$skip: skip $skip: skip,
disabled: false
} }
}); });
total = partialResponse.total; total = partialResponse.total;

View File

@ -7,10 +7,12 @@ function addProtocol(url, protocol) {
} }
function stripProtocol(url){ function stripProtocol(url){
if(!url) return '';
return url.replace(/(^\w+:|^)\/\//, ''); return url.replace(/(^\w+:|^)\/\//, '');
} }
function getProtocol(url){ function getProtocol(url){
if(!url) return '';
const values = url.match(/(^\w+:|^)\/\//); const values = url.match(/(^\w+:|^)\/\//);
return values && (values.length > 0) ? values[0] : ''; return values && (values.length > 0) ? values[0] : '';