version)) { $package = json_decode(f::read(dirname(__DIR__) . DS . 'package.json')); $this->version = $package->version; } return $this->version; } public function root() { return dirname(__DIR__); } public function license() { $key = kirby()->option('imagekit.license'); $type = 'trial'; /** * Hey there, * * if you have digged deep into Kirby’s source code, * than you’ve probably stumbled across a similiar * message, asking you to be honest when using the * software. I ask you the same, if your intention is to * use ImageKit. Writing this plugin took a lot of time * and it hopefully saves you a lot of headaches. If you * would use a cloud-provider instead of rolling your own * thumb engine, then your would also have to pay them. * * Anyway, have a nice day! * * Fabian */ if (str::startsWith($key, 'IMGKT1') && str::length($key) === 39) { $type = 'ImageKit 1'; } else { $key = null; } return new Obj(array( 'key' => $key, 'type' => $type, )); } }