From 36b1016d57af5dfafaeb4b0fccaf4d983048d7bc Mon Sep 17 00:00:00 2001 From: Ivan Goncharov Date: Wed, 22 May 2019 15:07:29 +0300 Subject: [PATCH] findBreakingChanges: Remove 'export' from internal functions Note: Only functions exported by `index.js` are treated as part of Public API https://github.com/graphql/graphql-js/blob/c0cf659d5036d2ec536a8805bc993cf85936d26d/src/utilities/index.js#L124-L130 --- src/utilities/findBreakingChanges.js | 32 ++++++++++++++-------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/src/utilities/findBreakingChanges.js b/src/utilities/findBreakingChanges.js index f4c22359d6..c55dfad874 100644 --- a/src/utilities/findBreakingChanges.js +++ b/src/utilities/findBreakingChanges.js @@ -116,7 +116,7 @@ export function findDangerousChanges( * Given two schemas, returns an Array containing descriptions of any breaking * changes in the newSchema related to removing an entire type. */ -export function findRemovedTypes( +function findRemovedTypes( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -139,7 +139,7 @@ export function findRemovedTypes( * Given two schemas, returns an Array containing descriptions of any breaking * changes in the newSchema related to changing the type of a type. */ -export function findTypesThatChangedKind( +function findTypesThatChangedKind( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -171,7 +171,7 @@ export function findTypesThatChangedKind( * (such as removal or change of type of an argument, or a change in an * argument's default value). */ -export function findArgChanges( +function findArgChanges( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): { @@ -295,7 +295,7 @@ function typeKindName(type: GraphQLNamedType): string { throw new TypeError('Unknown type ' + type.constructor.name); } -export function findFieldsThatChangedTypeOnObjectOrInterfaceTypes( +function findFieldsThatChangedTypeOnObjectOrInterfaceTypes( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -350,7 +350,7 @@ export function findFieldsThatChangedTypeOnObjectOrInterfaceTypes( return breakingChanges; } -export function findFieldsThatChangedTypeOnInputObjectTypes( +function findFieldsThatChangedTypeOnInputObjectTypes( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): { @@ -497,7 +497,7 @@ function isChangeSafeForInputObjectFieldOrFieldArg( * Given two schemas, returns an Array containing descriptions of any breaking * changes in the newSchema related to removing types from a union type. */ -export function findTypesRemovedFromUnions( +function findTypesRemovedFromUnions( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -531,7 +531,7 @@ export function findTypesRemovedFromUnions( * Given two schemas, returns an Array containing descriptions of any dangerous * changes in the newSchema related to adding types to a union type. */ -export function findTypesAddedToUnions( +function findTypesAddedToUnions( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -564,7 +564,7 @@ export function findTypesAddedToUnions( * Given two schemas, returns an Array containing descriptions of any breaking * changes in the newSchema related to removing values from an enum type. */ -export function findValuesRemovedFromEnums( +function findValuesRemovedFromEnums( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -598,7 +598,7 @@ export function findValuesRemovedFromEnums( * Given two schemas, returns an Array containing descriptions of any dangerous * changes in the newSchema related to adding values to an enum type. */ -export function findValuesAddedToEnums( +function findValuesAddedToEnums( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -629,7 +629,7 @@ export function findValuesAddedToEnums( return valuesAddedToEnums; } -export function findInterfacesRemovedFromObjectTypes( +function findInterfacesRemovedFromObjectTypes( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -660,7 +660,7 @@ export function findInterfacesRemovedFromObjectTypes( return breakingChanges; } -export function findInterfacesAddedToObjectTypes( +function findInterfacesAddedToObjectTypes( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -691,7 +691,7 @@ export function findInterfacesAddedToObjectTypes( return interfacesAddedToObjectTypes; } -export function findRemovedDirectives( +function findRemovedDirectives( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -726,7 +726,7 @@ function findRemovedArgsForDirective( return removedArgs; } -export function findRemovedDirectiveArgs( +function findRemovedDirectiveArgs( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -766,7 +766,7 @@ function findAddedArgsForDirective( return addedArgs; } -export function findAddedNonNullDirectiveArgs( +function findAddedNonNullDirectiveArgs( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array { @@ -794,7 +794,7 @@ export function findAddedNonNullDirectiveArgs( return addedNonNullableArgs; } -export function findRemovedLocationsForDirective( +function findRemovedLocationsForDirective( oldDirective: GraphQLDirective, newDirective: GraphQLDirective, ): Array { @@ -810,7 +810,7 @@ export function findRemovedLocationsForDirective( return removedLocations; } -export function findRemovedDirectiveLocations( +function findRemovedDirectiveLocations( oldSchema: GraphQLSchema, newSchema: GraphQLSchema, ): Array {