Fix pools schema

This commit is contained in:
Aleksandr Kraiz
2023-03-15 13:15:24 +04:00
parent ba410e13c1
commit d6dcbab128
3 changed files with 18 additions and 10 deletions

8
src/addressSchema.ts Normal file
View File

@@ -0,0 +1,8 @@
import { ethers } from 'ethers';
import { z } from 'zod';
const addressSchema = z.string().refine(ethers.utils.isAddress, (value) => ({
message: `Should be an address, got ${value}`,
}));
export default addressSchema;