Skip to content

Commit 937eba1

Browse files
author
Robin Frischmann
committed
added value type check for old flexbox props
1 parent 888d800 commit 937eba1

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

modules/plugins/flexboxOld.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export default function flexboxOld({ property, value, styles, browserInfo: { bro
3434
if (!keepUnprefixed && !Array.isArray(styles[property])) {
3535
delete styles[property]
3636
}
37-
if (property === 'flexDirection') {
37+
if (property === 'flexDirection' && typeof value === 'string') {
3838
return {
3939
WebkitBoxOrient: value.indexOf('column') > -1 ? 'vertical' : 'horizontal',
4040
WebkitBoxDirection: value.indexOf('reverse') > -1 ? 'reverse' : 'normal'

modules/static/plugins/flexboxOld.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const alternativeProps = {
1414
}
1515

1616
export default function flexboxOld(property, value) {
17-
if (property === 'flexDirection') {
17+
if (property === 'flexDirection' && typeof value === 'string') {
1818
return {
1919
WebkitBoxOrient: value.indexOf('column') > -1 ? 'vertical' : 'horizontal',
2020
WebkitBoxDirection: value.indexOf('reverse') > -1 ? 'reverse' : 'normal'

0 commit comments

Comments
 (0)