New structure of commands [php-graphene-node-client]

View this thread on: d.buzz | hive.blog | peakd.com | ecency.com
·@semasping·
0.000 HBD
New structure of commands [php-graphene-node-client]
In my pull requests new structure of commands. This is due to changes in the GOLOS blockchain.

Old way to get information from blockchain:
```
            $commandQuery = new CommandQueryData();
            $commandQuery->setParamByKey('0', $author);
            $commandQuery->setParamByKey('1', $permlink);

            $command = new GetContentCommand(new GolosApiWsConnector());
            $content = $command->execute($commandQuery);
```

New way:
```
            $commandQuery = new CommandQueryData();
            $commandQuery->setParamByKey('0', $author);
            $commandQuery->setParamByKey('1', $permlink);

            $command = new Command(new GolosApiWsConnector());

            $command = $command->get_content();

            $content = $command->execute($commandQuery);
```
Links to pull requests:
* https://github.com/t3ran13/php-graphene-node-client/pull/12
* https://github.com/t3ran13/php-graphene-node-client/pull/11


<br /><hr/><em>Posted on <a href="https://utopian.io/utopian-io/@semasping/new-structure-of-commands-php-graphene-node-client">Utopian.io -  Rewarding Open Source Contributors</a></em><hr/>
👍 , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,