Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions slick/slick.js
Original file line number Diff line number Diff line change
Expand Up @@ -1858,7 +1858,7 @@
var _ = this, breakpoint, currentBreakpoint, l,
responsiveSettings = _.options.responsive || null;

if ( $.type(responsiveSettings) === 'array' && responsiveSettings.length ) {
if ( Array.isArray(responsiveSettings) && responsiveSettings.length ) {

_.respondTo = _.options.respondTo || 'window';

Expand Down Expand Up @@ -2118,19 +2118,19 @@

var _ = this, l, item, option, value, refresh = false, type;

if( $.type( arguments[0] ) === 'object' ) {
if( typeof arguments[0] === 'object' ) {

option = arguments[0];
refresh = arguments[1];
type = 'multiple';

} else if ( $.type( arguments[0] ) === 'string' ) {
} else if ( typeof arguments[0] === 'string' ) {

option = arguments[0];
value = arguments[1];
refresh = arguments[2];

if ( arguments[0] === 'responsive' && $.type( arguments[1] ) === 'array' ) {
if ( arguments[0] === 'responsive' && Array.isArray(arguments[1]) ) {

type = 'responsive';

Expand Down Expand Up @@ -2160,7 +2160,7 @@

for ( item in value ) {

if( $.type( _.options.responsive ) !== 'array' ) {
if( !Array.isArray( _.options.responsive ) ) {

_.options.responsive = [ value[item] ];

Expand Down
Loading