Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crickey!: "Call to a member function getTimestamp() on boolean" #76

Open
Daryadi-S opened this issue Nov 15, 2018 · 1 comment
Open
Labels

Comments

@Daryadi-S
Copy link

Daryadi-S commented Nov 15, 2018

Hello. I'm working on an migration script to import my posts and comments from Google Blogger to Grav. Everything working fine, the comments are also rendered normally on the live pages.

But when try to view the latest comments on "localhost/grav/admin/comments/", I get an error like this: "Call to a member function getTimestamp() on boolean".

screenshot-20181115_122145

The comment.yaml files are imported like this:

title: 'Xposed Installer APK Fix Android 4.4.4 by Solarwarez Application Download'
lang: false
comments:
  - {"text":"gan saya pake cyanogenMod 12.1 beta cocoknya pake xposed installer apa","date":"2016-03-30T03:31:10.200+07:00","author":"Hendry Wijayanto","email":"[email protected]","uri":"https://www.blogger.com/profile/16304488146178401806"}
  - {"text":"Hmm... Kalo gak salah ada xposed khusus buat Android Lollipop, cari aja di repo.xposed.info","date":"2016-03-30T11:41:36.355+07:00","author":"iday raD","email":"[email protected]","uri":"https://www.blogger.com/profile/13765705053643369839"}
  - {"text":"ok makasih gan.blognya bagus selalu update","date":"2016-03-31T02:12:50.493+07:00","author":"Hendry Wijayanto","email":"[email protected]","uri":"https://www.blogger.com/profile/16304488146178401806"}
@Daryadi-S
Copy link
Author

It seems I have to convert the Date to the exact format like showed on the error line 308 above, including leading '0': D, d M Y H:i:s. Well, this is confusing for me because the old date format is fine and interpretted correctly as date value in page frontmatter 😁

This fixes it:

title: 'Xposed Installer APK Fix Android 4.4.4 by Solarwarez Application Download'
lang: false
comments:
  - {"text":"gan saya pake cyanogenMod 12.1 beta cocoknya pake xposed installer apa","date":"Wed, 30 March 2016 03:31:10","author":"Hendry Wijayanto","email":"[email protected]","uri":"https://www.blogger.com/profile/16304488146178401806"}
  - {"text":"Hmm... Kalo gak salah ada xposed khusus buat Android Lollipop, cari aja di repo.xposed.info","date":"Wed, 30 March 2016 11:41:36","author":"iday raD","email":"[email protected]","uri":"https://www.blogger.com/profile/13765705053643369839"}
  - {"text":"ok makasih gan.blognya bagus selalu update","date":"Thu, 31 March 2016 02:12:50","author":"Hendry Wijayanto","email":"[email protected]","uri":"https://www.blogger.com/profile/16304488146178401806"}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants