Skip to content

I have to use two Connection guard. Can I use only one Connection guard #1799

Discussion options

You must be logged in to vote

I believe you can use either &Connection<Db> or &mut Connection<Db> in both exist_by_mobile and insert, which will allow you to reuse the same connection for both.

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@paulzhang5511
Comment options

@bubelov
Comment options

@paulzhang5511
Comment options

@bubelov
Comment options

Answer selected by paulzhang5511
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants