title: Type '[]' is missing the following properties from type ''" graphql
body: <p>I have a simple Resolver in <strong>typeGraphQL</strong> which <strong>findOne</strong> and returns a record against the query,i have a similar implementation for <strong>Company</strong> model that works just fine, but the <strong>Product</strong> doesnot work, let me show you my code</p>
  <p><strong>entity/Product.ts</strong></p>
  <pre><code>import { Entity, PrimaryGeneratedColumn, Column, BaseEntity } from &quot;typeorm&quot;;
  import { ObjectType, Field, ID } from &quot;type-graphql&quot;;
  
  //the field decorator represents which fields user can query
  
  @ObjectType()
  @Entity()
  export class Product extends BaseEntity {
    @Field(() =&gt; ID)
    @PrimaryGeneratedColumn() 
    id: number;
  
    @Field({nullable: true})
    @Column({length: 300, nullable: true})
    description: string;
  
    @Field({nullable: true})
    @Column({length: 300, nullable: true})
    image: string;
  
    @Field({nullable: true})
    @Column({ length: 300, nullable: true })
    stock: string;
  
    @Field({nullable: true})
    @Column({ length: 300, nullable: true })
    color: string;
  
    @Field()
    @Column({length: 300})
    name: string;
  
    @Field()
    @Column({length: 300})
    company_id: string;
  }
  </code></pre>
  <p><strong>Resolver</strong></p>
  <pre><code>import { Resolver, Query,Arg } from &quot;type-graphql&quot;;
  import { Product } from &quot;../../entity/Product&quot;;
  
  
  @Resolver()
  export class ProductResolver {
  
    @Query(() =&gt; Product)
    async companyProducts(
      @Arg(&quot;name&quot;) company_id: string,
    ): Promise&lt;Product | null&gt; {
      const product=await Product.findOne({ where: { company_id } });
      console.log(product)
      return product;
      // return product;
    }
  }
  </code></pre>
  <p>the console.log() does print out the expected object but when i return I am getting</p>
  <pre><code>Type 'Product | undefined' is not assignable to type 'Product | null'.
  </code></pre>
  <p>any idea what might be the reason?</p>