File tree Expand file tree Collapse file tree 3 files changed +2
-8
lines changed Expand file tree Collapse file tree 3 files changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,6 @@ function getAllPosts(param) {
26
26
var nonArchivedPosts = mdxFiles ( postsDirectory ) . map ( function ( path ) {
27
27
var match = GrayMatter ( Fs . readFileSync ( Path . join ( postsDirectory , path ) , "utf8" ) ) ;
28
28
return {
29
- content : match . content ,
30
29
path : path ,
31
30
archived : false ,
32
31
frontmatter : match . data
@@ -35,7 +34,6 @@ function getAllPosts(param) {
35
34
var archivedPosts = mdxFiles ( archivedPostsDirectory ) . map ( function ( path ) {
36
35
var match = GrayMatter ( Fs . readFileSync ( Path . join ( archivedPostsDirectory , path ) , "utf8" ) ) ;
37
36
return {
38
- content : match . content ,
39
37
path : Path . join ( "archive" , path ) ,
40
38
archived : true ,
41
39
frontmatter : match . data
Original file line number Diff line number Diff line change @@ -33,7 +33,6 @@ module GrayMatter = {
33
33
}
34
34
35
35
type postData = {
36
- content : string ,
37
36
path : string ,
38
37
archived : bool ,
39
38
frontmatter : Js .Json .t ,
@@ -54,22 +53,20 @@ let getAllPosts = () => {
54
53
}
55
54
56
55
let nonArchivedPosts = mdxFiles (postsDirectory )-> Js .Array2 .map (path => {
57
- let {GrayMatter .data : data , content } =
56
+ let {GrayMatter .data : data } =
58
57
Node .Path .join2 (postsDirectory , path )-> Node .Fs .readFileSync (#utf8 )-> GrayMatter .matter
59
58
{
60
59
path : path ,
61
- content : content ,
62
60
frontmatter : data ,
63
61
archived : false ,
64
62
}
65
63
})
66
64
67
65
let archivedPosts = mdxFiles (archivedPostsDirectory )-> Js .Array2 .map (path => {
68
- let {GrayMatter .data : data , content } =
66
+ let {GrayMatter .data : data } =
69
67
Node .Path .join2 (archivedPostsDirectory , path )-> Node .Fs .readFileSync (#utf8 )-> GrayMatter .matter
70
68
{
71
69
path : Node .Path .join2 ("archive" , path ),
72
- content : content ,
73
70
frontmatter : data ,
74
71
archived : true ,
75
72
}
Original file line number Diff line number Diff line change 1
1
type postData = {
2
- content : string ,
3
2
path : string ,
4
3
archived : bool ,
5
4
frontmatter : Js .Json .t ,
You can’t perform that action at this time.
0 commit comments