Log message #4121430

# At Username Text
# Mar 2nd 2018, 18:00 obinoob savant yes the relationship is hasMany but it still makes sense since first() === limit => 1, so if it conditions accept 'limit' key I don't see why not return "certificate" object?!?
# Mar 2nd 2018, 17:58 lordyuri92 hello
# Mar 2nd 2018, 17:55 savant since the relationship is hasMany
# Mar 2nd 2018, 17:55 savant cant do that
# Mar 2nd 2018, 17:55 obinoob so when printing in view instead $users->certificates[0]->number as opposed to $users->certificates->number
# Mar 2nd 2018, 17:54 obinoob as the query runs separately makes sense I could get an object as within first() etc
# Mar 2nd 2018, 17:53 savant an array index for what
# Mar 2nd 2018, 17:53 obinoob I've used 'limit' => 1 but nope
# Mar 2nd 2018, 17:52 obinoob savant when passing ->contain() optional table (I know that it will exist only one registry matching my rules) instead of getting an array index I would like to know if I can get an object ex: https://pastebin.com/w0jU1Hyb
# Mar 2nd 2018, 17:48 savant what?
# Mar 2nd 2018, 17:47 obinoob any chance of getting an object for only one registry within contain() or find('all', ['contain' => [...]]) I've used 'limit' = 1 but still got an array
# Mar 2nd 2018, 17:22 inoas and a fun weekend!
# Mar 2nd 2018, 17:21 inoas have a great evening bakers!
# Mar 2nd 2018, 16:58 admad also checkout `App::shortName(get_class($entity))`
# Mar 2nd 2018, 16:56 rudy1976s that's ok that way
# Mar 2nd 2018, 16:56 savant probably.
# Mar 2nd 2018, 16:56 savant and the last will be the classname
# Mar 2nd 2018, 16:56 savant and the first will be the plugin
# Mar 2nd 2018, 16:56 rudy1976s ah okay
# Mar 2nd 2018, 16:56 savant you can assume that you can split that string by Model\Entity
# Mar 2nd 2018, 16:56 rudy1976s I am at that point
# Mar 2nd 2018, 16:56 savant since its an entity
# Mar 2nd 2018, 16:56 rudy1976s exact
# Mar 2nd 2018, 16:56 savant and that will return the full-namespaced class nam
# Mar 2nd 2018, 16:55 savant get_class($entity)
# Mar 2nd 2018, 16:55 savant err
# Mar 2nd 2018, 16:55 savant https://gist.github.com/jasondmoss/6200807
# Mar 2nd 2018, 16:55 rudy1976s I try to explain better
# Mar 2nd 2018, 16:55 savant but you can do
# Mar 2nd 2018, 16:54 savant I dont think entities have their plugin anywhere
# Mar 2nd 2018, 16:52 rudy1976s I have a question: I have a entity object and I need to extract plugin and class name: how can I do that?
# Mar 2nd 2018, 16:51 rudy1976s Good evening
# Mar 2nd 2018, 15:02 inoas in case url, query params and (non-ignored) headers are the same
# Mar 2nd 2018, 15:02 inoas and if cache is enabled through Configure it gets that from a cachedClient cache config (at the moment Apcu)
# Mar 2nd 2018, 15:01 inoas at the moment I just added a getCachedBody() method to CachedClient()
# Mar 2nd 2018, 15:01 inoas anyway I will let you know if things work out
# Mar 2nd 2018, 15:01 inoas so every time you would get back a different respose (in this case a different token, best case from the cache, non-blocking filling up the buffer/pool behind)
# Mar 2nd 2018, 15:00 inoas consume because obviously POST would not be idempotent
# Mar 2nd 2018, 15:00 inoas and if the token server doesn't respond you still have a pool to "consume"
# Mar 2nd 2018, 14:59 inoas you would get 100 tokens ahead of time and once you are down to say 10, you fetch another 100, or you refill immediatly
# Mar 2nd 2018, 14:59 inoas well if you get some tokens from a server