How to fix Argument of type 'null' is not assignable to parameter of type 'string' in TypeScript | DevErrors