mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2025-01-10 18:27:25 +03:00
Removed unecesary check
This commit is contained in:
parent
ed1f650fc6
commit
7d6afd47b1
1 changed files with 1 additions and 5 deletions
|
@ -23,11 +23,7 @@ import { stringifyQuery } from '../../utils/helpers/query';
|
|||
const buildShlinkBaseUrl = (url: string, apiVersion: number) => url ? `${url}/rest/v${apiVersion}` : '';
|
||||
const rejectNilProps = reject(isNil);
|
||||
const normalizeOrderByInParams = (params: ShlinkShortUrlsListParams): ShlinkShortUrlsListNormalizedParams => {
|
||||
if (!params.orderBy) {
|
||||
return params as ShlinkShortUrlsListNormalizedParams;
|
||||
}
|
||||
|
||||
const { orderBy, ...rest } = params;
|
||||
const { orderBy = {}, ...rest } = params;
|
||||
const [ firstKey ] = Object.keys(orderBy);
|
||||
const [ firstValue ] = Object.values(orderBy);
|
||||
|
||||
|
|
Loading…
Reference in a new issue