Skip to content

Point,Size,Bounds判断的修改#147

Open
MingYinLv wants to merge 3 commits into
JserWang:masterfrom
MingYinLv:master
Open

Point,Size,Bounds判断的修改#147
MingYinLv wants to merge 3 commits into
JserWang:masterfrom
MingYinLv:master

Conversation

@MingYinLv

Copy link
Copy Markdown

Point接收的参数为两个Number类型,只需要判断是否为number类型就可以了,lng和lat在国外有为负数的情况,当前的判断有问题,如果出现负数会报错,而且只判断了lng,typeof返回的是字符串,lat永远都是true,下面的Size是同样的问题,只需要接收number类型的参数就足够了。
Bounds的sw和ne百度地图的文档是Point类型,现在是把他们当初number类型来判断。

@ivshow ivshow left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also found the bug, hope to merge!

@MingYinLv

Copy link
Copy Markdown
Author

修改了一下,只对经纬度进行负数兼容

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants