Skip to content

Commit

Permalink
Improved example
Browse files Browse the repository at this point in the history
  • Loading branch information
ankane committed Dec 3, 2023
1 parent d043232 commit 8dcb3dd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ SqlMapper.AddTypeHandler(new VectorTypeHandler());

var dataSourceBuilder = new NpgsqlDataSourceBuilder(connString);
dataSourceBuilder.UseVector();
await using var dataSource = dataSourceBuilder.Build();
var dataSource = dataSourceBuilder.Build();

var conn = dataSource.OpenConnection();
```
Expand Down
4 changes: 2 additions & 2 deletions tests/Pgvector.CSharp.Tests/DapperTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ public class DapperItem
public class DapperTests
{
[Fact]
public async Task Main()
public void Main()
{
SqlMapper.AddTypeHandler(new VectorTypeHandler());

var connString = "Host=localhost;Database=pgvector_dotnet_test";

var dataSourceBuilder = new NpgsqlDataSourceBuilder(connString);
dataSourceBuilder.UseVector();
await using var dataSource = dataSourceBuilder.Build();
var dataSource = dataSourceBuilder.Build();

var conn = dataSource.OpenConnection();

Expand Down

0 comments on commit 8dcb3dd

Please sign in to comment.