Skip to content

Commit 7d09a39

Browse files
committed
fix: isPlainObject (#598)
1 parent 7cf403e commit 7d09a39

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/plugins/playlist/playlist.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import isObject from 'lodash/isObject';
1+
import isPlainObject from 'lodash/isPlainObject';
22
import { sliceProperties } from 'utils/slicing';
33
import { PLAYER_EVENT } from 'utils/consts';
44
import { getCloudinaryUrl } from 'plugins/cloudinary/common';
@@ -22,7 +22,7 @@ const playlist = (player, options = {}) => {
2222
playlistWidget.dispose();
2323
}
2424

25-
if (isObject(options.playlistWidget)) {
25+
if (isPlainObject(options.playlistWidget)) {
2626
if (player.fluid_) {
2727
options.playlistWidget.fluid = true;
2828
}

src/plugins/playlist/utils/api.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
import camelCase from 'lodash/camelCase';
2-
import isObject from 'lodash/isObject';
2+
import isPlainObject from 'lodash/isPlainObject';
33
import { parseISO8601 } from './time';
44

55
const TIME_FIELDS = ['created_at', 'updated_at'];
66

77
const normalizeJsonResponse = (obj) => {
88
const agg = {};
99

10-
if (isObject(obj)) {
10+
if (isPlainObject(obj)) {
1111
Object.keys(obj).reduce((agg, key) => {
1212
const newKey = camelCase(key);
1313

0 commit comments

Comments
 (0)