FAQ Database Discussion Community

Parse.Cloud.httpRequest httpresponse does not match cUrl response

curl,parse.com,bitcoin,chain
I would like to get the same HTTP response from Parse.com cloud code calling Parse.Cloud.httpRequest as I've got from cUrl. But I can't get it. Does anybody know what am I doing wrong? cUrl example: curl https://api.chain.com/v2/bitcoin/transactions/917673efa435b483343ddfe373995df365260c617107d3f9de68abd4e97c981b/confidence?api-key-id=e8d5ed773cf24e31c149ae874eb23c74 response from cUrl: { "transaction_hash":"917673efa435b483343ddfe373995df365260c617107d3f9de68abd4e97c981b",...

javascript,jquery,null,undefined,chain
Sometimes I'd like to add class in chain, under some condition. What value would be semantically most appropriate to add no class? Example: $(".element").doSomething().addClass(condition ? "special-class" : undefined).doSomethingElse(); Or:$(".element").doSomething().addClass(condition ? "special-class" : null).doSomethingElse(); ...

How to connect nodes with TikZ chain like this example?

chain,tikz
After reading How to connect nodes with TikZ?,I am thinking about how to convert below simple example to use TiKz chain. Current MWE: \documentclass[tikz]{standalone} \usetikzlibrary{arrows,positioning,calc} \tikzset{ block/.style={draw,text width=2em,minimum height=1em,align=center}, arrow/.style={->} } \newcommand\connect[2]{\path[draw,arrow] (#1) |- ($(#1)!1/2!(#2)$) -| (#2)} \begin{document} \begin{tikzpicture}[>=stealth'] \node[block] (N1) {N1}; \node[block,below=1cm of N1,xshift=-1cm] (N2) {N2}; \connect{N1}{N2}; \end{tikzpicture}...

Conditional execution of resources

chef,condition,chain
I have the following 2 resources defined within a cookbook that makes HTTP requests. I essentially need to execute action 2 based on checking a condition from the result of action 1. If the condition from action 1 does not match I need the cookbook to sleep for a period...