Leaflet Blog in Deno Fresh

Update api.ts

+3 -3
+3 -3
lib/api.ts
··· 15 return posts.data.records.filter( 16 drafts, 17 ) as (ComAtprotoRepoListRecords.Record & { 18 - value: ComWhtwndBlogEntry.Record; 19 })[]; 20 } 21 22 function drafts(record: ComAtprotoRepoListRecords.Record) { 23 if (Deno.env.get("NODE_ENV") === "development") return true; 24 - const post = record.value as ComWhtwndBlogEntry.Record; 25 return post.visibility === "public"; 26 } 27 ··· 35 }); 36 37 return post.data as ComAtprotoRepoListRecords.Record & { 38 - value: ComWhtwndBlogEntry.Record; 39 }; 40 }
··· 15 return posts.data.records.filter( 16 drafts, 17 ) as (ComAtprotoRepoListRecords.Record & { 18 + value: ComWhtwndBlogEntry.Main; 19 })[]; 20 } 21 22 function drafts(record: ComAtprotoRepoListRecords.Record) { 23 if (Deno.env.get("NODE_ENV") === "development") return true; 24 + const post = record.value as ComWhtwndBlogEntry.Main; 25 return post.visibility === "public"; 26 } 27 ··· 35 }); 36 37 return post.data as ComAtprotoRepoListRecords.Record & { 38 + value: ComWhtwndBlogEntry.Main; 39 }; 40 }