module import { hasSortKey , Metadata } from '../../decorator/metadata/metadata' ; import { attribute } from './logical-operator/public.api' ; import { ConditionExpressionDefinitionFunction } from './type/condition-expression-definition-function' ; hidden export function createIfNotExistsCondition < T > ( metadata ) { const conditionDefFns = [ attribute < T > ( metadata . getPartitionKey ( ) ) . attributeNotExists ( ) , ] ; if ( hasSortKey ( metadata ) ) { conditionDefFns . push ( attribute < T > ( metadata . getSortKey ( ) ) . attributeNotExists ( ) ) ; } return conditionDefFns ; }