Skip to content

Conversation

@ZhihuiTian
Copy link

No description provided.

@phpmaple
Copy link

approved?

Copy link
Contributor

@yjbanov yjbanov left a comment

Choose a reason for hiding this comment

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

Thank you for the PR and sorry for the delay. This looks like a good feature.

Can you please add tests for this?

@visibleForTesting
String get postUri =>
'${dsnUri.scheme}://${dsnUri.host}/api/$projectId/store/';
'${dsnUri.scheme}://${dsnUri.host}${dsnUri.port != 80 && dsnUri.port != 443 ? ':' + dsnUri.port.toString() : ''}/api/$projectId/store/';
Copy link
Contributor

Choose a reason for hiding this comment

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

This is probably a good time to switch from the => shorthand to a { } block syntax, and make port a variable.

@visibleForTesting
String get postUri =>
'${dsnUri.scheme}://${dsnUri.host}/api/$projectId/store/';
'${dsnUri.scheme}://${dsnUri.host}${dsnUri.port != 80 && dsnUri.port != 443 ? ':' + dsnUri.port.toString() : ''}/api/$projectId/store/';
Copy link
Contributor

Choose a reason for hiding this comment

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

':' + dsnUri.port.toString() can be replaced with ':${dsnUri.port}'

@MrMoronIV
Copy link

Can this be pulled into master?

My SDN:

https://dc31d4db460d4c198241b52537d90bc6:[email protected]:9500/6

After a while I get:

Unhandled Exception: SocketException: OS Error: Connection refused, errno = 111, address = err.domain.com, port = 50563

I tried again:

Unhandled Exception: SocketException: OS Error: Connection refused, errno = 111, address = err.domain.com, port = 50564

without defining a port it says: port = 50566

@yjbanov
Copy link
Contributor

yjbanov commented Oct 15, 2019

It seems #42 covers this feature, as well as adds support for custom paths. So I'll close this PR in favor of #42.

@yjbanov yjbanov closed this Oct 15, 2019
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.

4 participants