I need help debugging

Discussion in 'Requests' started by Viyen, Jun 16, 2021.

  1. Viyen

    Viyen Spider

    Messages:
    7
    GitHub:
    Viyen
    Parse error: syntax error, unexpected ';'
    $after = $action;
     
  2. minijaham

    minijaham Zombie Pigman

    Messages:
    771
    GitHub:
    minijaham
    You need help debugging for a simple syntax error???
     
  3. Viyen

    Viyen Spider

    Messages:
    7
    GitHub:
    Viyen
    I'm not good at programming can you help me fix it
     
  4. minijaham

    minijaham Zombie Pigman

    Messages:
    771
    GitHub:
    minijaham
    send me your code before the error line
     
  5. Viyen

    Viyen Spider

    Messages:
    7
    GitHub:
    Viyen
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: ParseError: "syntax error, unexpected ';'" (EXCEPTION) in "plugins/TradeAPI-stable/src/nlog/trade/listener/TransactionInjector" at line 42
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #0 pmsrc/vendor/pocketmine/classloader/src/BaseClassLoader(124): BaseClassLoader->loadClass(string[39] nlog\trade\listener\TransactionInjector)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #1 (): BaseClassLoader->{closure}(string[39] nlog\trade\listener\TransactionInjector)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #2 plugins/TradeAPI-stable/src/nlog/trade/TradeAPI(80): spl_autoload_call(string[39] nlog\trade\listener\TransactionInjector)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #3 pmsrc/src/pocketmine/plugin/PluginBase(116): nlog\trade\TradeAPI->onEnable()
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #4 pmsrc/src/pocketmine/plugin/PluginManager(552): pocketmine\plugin\PluginBase->setEnabled(boolean 1)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #5 pmsrc/src/pocketmine/Server(1785): pocketmine\plugin\PluginManager->enablePlugin(object nlog\trade\TradeAPI)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #6 pmsrc/src/pocketmine/Server(1771): pocketmine\Server->enablePlugin(object nlog\trade\TradeAPI)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #7 plugins/PocketMine-DevTools.phar/src/DevTools/DevTools(71): pocketmine\Server->enablePlugins(integer 0)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #8 pmsrc/src/pocketmine/plugin/PluginBase(116): DevTools\DevTools->onEnable()
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #9 pmsrc/src/pocketmine/plugin/PluginManager(552): pocketmine\plugin\PluginBase->setEnabled(boolean 1)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #10 pmsrc/src/pocketmine/Server(1785): pocketmine\plugin\PluginManager->enablePlugin(object DevTools\DevTools)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #11 pmsrc/src/pocketmine/Server(1771): pocketmine\Server->enablePlugin(object DevTools\DevTools)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #12 pmsrc/src/pocketmine/Server(1530): pocketmine\Server->enablePlugins(integer 0)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #13 pmsrc/src/pocketmine/PocketMine(291): pocketmine\Server->__construct(object BaseClassLoader, object pocketmine\utils\MainLogger, string[72] /storage/emulated/0/Android/data/io.scer.pocketmine/files/PocketMine-MP/, string[80] /storage/emulated/0/Android/data/io.scer.pocketmine/files/PocketMine-MP/plugins/)
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #14 pmsrc/src/pocketmine/PocketMine(321): pocketmine\server()
    2021-06-17 [00:54:15] [Server thread/CRITICAL]: #15 pmsrc(11): require(string[127] phar:///storage/emulated/0/Android/data/io.scer.pocketmine/files/PocketMine-MP/P)
     

    Attached Files:

  6. minijaham

    minijaham Zombie Pigman

    Messages:
    771
    GitHub:
    minijaham
    Learn PHP first.
    You didn't even provide enough arguments to foreach()
     
  7. BestCodrEcer

    BestCodrEcer Spider

    Messages:
    11
    GitHub:
    bestcodrever
    1. You are missing some arguments for foreach()
    2. You need extra parenthesis (not bracket, thanks minijaham) after getActions() on line 41.

    Here is the documentation for foreach()
    https://www.php.net/manual/en/control-structures.foreach.php
     
    Last edited: Jun 17, 2021
    minijaham likes this.
  8. minijaham

    minijaham Zombie Pigman

    Messages:
    771
    GitHub:
    minijaham
  9. BestCodrEcer

    BestCodrEcer Spider

    Messages:
    11
    GitHub:
    bestcodrever
    Whoops ok I edited my message :D
     
    minijaham likes this.

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.