mirror of
https://github.com/zoriya/react-native-svg.git
synced 2026-06-02 06:35:04 +00:00
Fix viewBox pre condition warning
This commit is contained in:
@@ -34,7 +34,7 @@ export default function(props) {
|
||||
.split(spacesRegExp)
|
||||
.map(Number);
|
||||
|
||||
if (params.length === 4 && params.some(isNaN)) {
|
||||
if (params.length !== 4 || params.some(isNaN)) {
|
||||
console.warn("Invalid `viewBox` prop:" + viewBox);
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user