Skip to content

Commit

Permalink
fix: realign after rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
bassgeta committed May 22, 2024
1 parent 6e9f9a7 commit 8e064c0
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 20 deletions.
24 changes: 12 additions & 12 deletions src/graphql/generated.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1462,7 +1462,7 @@ export type CreateDomainInput = {
isRoot: Scalars['Boolean'];
nativeFundingPotId: Scalars['Int'];
nativeId: Scalars['Int'];
nativeSkillId: Scalars['Int'];
nativeSkillId: Scalars['String'];
reputation?: InputMaybe<Scalars['String']>;
reputationPercentage?: InputMaybe<Scalars['String']>;
};
Expand Down Expand Up @@ -1890,7 +1890,7 @@ export type Domain = {
* Native skill ID of the Domain
* The native skill ID is assigned to a domain from the contract on creation
*/
nativeSkillId: Scalars['Int'];
nativeSkillId: Scalars['String'];
/** The amount of reputation in the domain */
reputation?: Maybe<Scalars['String']>;
/** The amount of reputation in the domain, as a percentage of the total in the colony */
Expand Down Expand Up @@ -3095,7 +3095,7 @@ export type ModelDomainConditionInput = {
isRoot?: InputMaybe<ModelBooleanInput>;
nativeFundingPotId?: InputMaybe<ModelIntInput>;
nativeId?: InputMaybe<ModelIntInput>;
nativeSkillId?: InputMaybe<ModelIntInput>;
nativeSkillId?: InputMaybe<ModelStringInput>;
not?: InputMaybe<ModelDomainConditionInput>;
or?: InputMaybe<Array<InputMaybe<ModelDomainConditionInput>>>;
reputation?: InputMaybe<ModelStringInput>;
Expand All @@ -3115,7 +3115,7 @@ export type ModelDomainFilterInput = {
isRoot?: InputMaybe<ModelBooleanInput>;
nativeFundingPotId?: InputMaybe<ModelIntInput>;
nativeId?: InputMaybe<ModelIntInput>;
nativeSkillId?: InputMaybe<ModelIntInput>;
nativeSkillId?: InputMaybe<ModelStringInput>;
not?: InputMaybe<ModelDomainFilterInput>;
or?: InputMaybe<Array<InputMaybe<ModelDomainFilterInput>>>;
reputation?: InputMaybe<ModelStringInput>;
Expand Down Expand Up @@ -3996,7 +3996,7 @@ export type ModelSubscriptionDomainFilterInput = {
isRoot?: InputMaybe<ModelSubscriptionBooleanInput>;
nativeFundingPotId?: InputMaybe<ModelSubscriptionIntInput>;
nativeId?: InputMaybe<ModelSubscriptionIntInput>;
nativeSkillId?: InputMaybe<ModelSubscriptionIntInput>;
nativeSkillId?: InputMaybe<ModelSubscriptionStringInput>;
or?: InputMaybe<Array<InputMaybe<ModelSubscriptionDomainFilterInput>>>;
reputation?: InputMaybe<ModelSubscriptionStringInput>;
reputationPercentage?: InputMaybe<ModelSubscriptionStringInput>;
Expand Down Expand Up @@ -6156,7 +6156,7 @@ export type QueryGetDomainByNativeSkillIdArgs = {
filter?: InputMaybe<ModelDomainFilterInput>;
limit?: InputMaybe<Scalars['Int']>;
nativeId?: InputMaybe<ModelIntKeyConditionInput>;
nativeSkillId: Scalars['Int'];
nativeSkillId: Scalars['String'];
nextToken?: InputMaybe<Scalars['String']>;
sortDirection?: InputMaybe<ModelSortDirection>;
};
Expand Down Expand Up @@ -8327,7 +8327,7 @@ export type UpdateDomainInput = {
isRoot?: InputMaybe<Scalars['Boolean']>;
nativeFundingPotId?: InputMaybe<Scalars['Int']>;
nativeId?: InputMaybe<Scalars['Int']>;
nativeSkillId?: InputMaybe<Scalars['Int']>;
nativeSkillId?: InputMaybe<Scalars['String']>;
reputation?: InputMaybe<Scalars['String']>;
reputationPercentage?: InputMaybe<Scalars['String']>;
};
Expand Down Expand Up @@ -8769,7 +8769,7 @@ export type ColonyFragment = {
items: Array<{
__typename?: 'Domain';
id: string;
nativeSkillId: number;
nativeSkillId: string;
} | null>;
} | null;
};
Expand Down Expand Up @@ -9682,7 +9682,7 @@ export type GetColonyQuery = {
items: Array<{
__typename?: 'Domain';
id: string;
nativeSkillId: number;
nativeSkillId: string;
} | null>;
} | null;
} | null;
Expand Down Expand Up @@ -9820,7 +9820,7 @@ export type GetDomainMetadataQuery = {
};

export type GetDomainByNativeSkillIdQueryVariables = Exact<{
nativeSkillId: Scalars['Int'];
nativeSkillId: Scalars['String'];
}>;

export type GetDomainByNativeSkillIdQuery = {
Expand All @@ -9830,7 +9830,7 @@ export type GetDomainByNativeSkillIdQuery = {
items: Array<{
__typename?: 'Domain';
id: string;
nativeSkillId: number;
nativeSkillId: string;
nativeId: number;
} | null>;
} | null;
Expand Down Expand Up @@ -11267,7 +11267,7 @@ export const GetDomainMetadataDocument = gql`
}
`;
export const GetDomainByNativeSkillIdDocument = gql`
query GetDomainByNativeSkillId($nativeSkillId: Int!) {
query GetDomainByNativeSkillId($nativeSkillId: String!) {
getDomainByNativeSkillId(nativeSkillId: $nativeSkillId) {
items {
id
Expand Down
2 changes: 1 addition & 1 deletion src/graphql/queries/domain.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ query GetDomainMetadata($id: ID!) {
}
}

query GetDomainByNativeSkillId($nativeSkillId: Int!) {
query GetDomainByNativeSkillId($nativeSkillId: String!) {
getDomainByNativeSkillId(nativeSkillId: $nativeSkillId) {
items {
id
Expand Down
4 changes: 2 additions & 2 deletions src/handlers/multiSig/multiSigCreated/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ export const getMultiSigData = async ({
};

const getDomainIdByNativeSkillId = async (
nativeSkillId: number,
nativeSkillId: string,
): Promise<number | null> => {
const result = await query<
GetDomainByNativeSkillIdQuery,
Expand Down Expand Up @@ -192,7 +192,7 @@ export const createMultiSigInDB = async (
const motion = await multiSigClient.getMotion(multiSigId);

const domainId = await getDomainIdByNativeSkillId(
motion.domainSkillId.toNumber(),
motion.domainSkillId.toString(),
);

if (domainId === null) {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/events.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export const saveEvent = async (event: ContractEvent): Promise<void> => {
id: `${chainId}_${transactionHash}_${logIndex}`,
agent: parsedArgs?.agent || contractAddress,
chainMetadata: {
chainId: Number(chainId), // @TODO why did this change?
chainId,
transactionHash,
logIndex,
blockNumber,
Expand Down
6 changes: 2 additions & 4 deletions src/utils/permissions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -592,11 +592,9 @@ export const createInitialMultiSigRolesDatabaseEntry = async (
contributorAddress: targetAddress,
});

const installedExtensions = new Set(
await getExtensionInstallations(colonyAddress),
);
const isExtension = await isAddressExtension(targetAddress);

if (!isContributor && !installedExtensions.has(targetAddress)) {
if (!isContributor && !isExtension) {
await createColonyContributor({
colonyAddress,
contributorAddress: targetAddress,
Expand Down

0 comments on commit 8e064c0

Please sign in to comment.