52% loja-automatica

Code Review | Loja Automática

WordPress plugin Loja Automática scored52%from 54 tests.

About plugin

  • Plugin page: loja-automatica
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.2.1
  • WordPress version: 6.3.1
  • First release: May 15, 2012
  • Latest release: May 27, 2012
  • Number of updates: 12
  • Update frequency: every 1.1 days
  • Top authors: eneasgesing (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,306 total downloads

Benchmarks

Plugin footprint 48% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.75MB] [CPU: ▼31.18ms] Passed 4 tests

This is a short check of server-side resources used by Loja Automática
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0937.53 ▼4.79
Dashboard /wp-admin3.20 ▼0.1126.49 ▼21.32
Posts /wp-admin/edit.php3.20 ▼0.1626.31 ▼24.18
Add New Post /wp-admin/post-new.php3.20 ▼2.6927.37 ▼67.59
Media Library /wp-admin/upload.php3.20 ▼0.0324.09 ▼11.63
Criar Categorias /wp-admin/admin.php?page=lojaautomatica-add-new3.2025.06
Adicionar Nova Oferta /wp-admin/post-new.php?post_type=oferta3.2028.83
Loja Automática /wp-admin/admin.php?page=lojaautomatica-campaigns3.2026.81
Ofertas /wp-admin/edit.php?post_type=oferta3.2026.72
Configurações /wp-admin/admin.php?page=lojaautomatica-settings3.2024.30
Categoria do ML /wp-admin/edit-tags.php?taxonomy=oferta_categoria&post_type=oferta3.2025.78

Server storage [IO: ▲0.19MB] [DB: ▲0.00MB] Passed 3 tests

Analyzing filesystem and database footprints of this plugin
This plugin was installed successfully
Filesystem: 18 new files
Database: 1 new table, 7 new options
New tables
wp_lojaautomatica
New WordPress options
widget_recent-comments
widget_recent-posts
lojaautomatica_opts
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Loja Automática
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,881 ▲13514.38 ▲0.011.97 ▲0.1740.31 ▼3.25
Dashboard /wp-admin2,259 ▲795.63 ▲0.02100.07 ▲6.4046.99 ▲3.14
Posts /wp-admin/edit.php2,161 ▲582.04 ▲0.0541.41 ▼1.4741.52 ▲0.55
Add New Post /wp-admin/post-new.php1,579 ▲5123.24 ▲0.25665.25 ▲56.9261.67 ▲11.42
Media Library /wp-admin/upload.php1,461 ▲644.20 ▲0.0499.80 ▼2.3743.05 ▼1.86
Criar Categorias /wp-admin/admin.php?page=lojaautomatica-add-new1,1012.2629.3625.71
Adicionar Nova Oferta /wp-admin/post-new.php?post_type=oferta2,4297.76192.0772.28
Loja Automática /wp-admin/admin.php?page=lojaautomatica-campaigns1,0532.0428.4630.46
Ofertas /wp-admin/edit.php?post_type=oferta1,1591.9131.9434.33
Configurações /wp-admin/admin.php?page=lojaautomatica-settings1,1432.0426.7032.38
Categoria do ML /wp-admin/edit-tags.php?taxonomy=oferta_categoria&post_type=oferta1,3412.1235.2634.72

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 25% from 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Warning in wp-content/plugins/loja-automatica/admin/admin.php+27
    Creating default object from empty value
  • Zombie tables were found after uninstall: 1 table
    • wp_lojaautomatica
  • This plugin did not uninstall successfully, leaving 7 options in the database
    • widget_theysaidso_widget
    • lojaautomatica_opts
    • widget_recent-comments
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These errors were triggered by the plugin
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/edit-tags.php?taxonomy=oferta_categoria&post_type=oferta
    • > Warning in wp-content/plugins/loja-automatica/admin/admin.php+27
    Creating default object from empty value
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=lojaautomatica-settings
    • > User deprecated in wp-includes/functions.php+5463
    Function screen_icon is deprecated since version 3.8.0 with no alternative available.
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=lojaautomatica-settings
    • > User deprecated in wp-includes/functions.php+5463
    Function get_screen_icon is deprecated since version 3.8.0 with no alternative available.

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following items
  • 9× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/loja-automatica/include/tools.php:56
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/loja-automatica/include/list_table.php on line 8
    • > PHP Warning
      Use of undefined constant LOJAAUTOMATICA_INC - assumed 'LOJAAUTOMATICA_INC' (this will throw an Error in a future version of PHP) in wp-content/plugins/loja-automatica/admin/admin.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/loja-automatica/include/tools.php:56
    • > PHP Warning
      require_once(LOJAAUTOMATICA_INClist_table.php): failed to open stream: No such file or directory in wp-content/plugins/loja-automatica/admin/admin.php on line 7
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/loja-automatica/include/list_table.php on line 8
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/loja-automatica/include/list_table.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/loja-automatica/include/custom_types.php:2
    • > PHP Fatal error
      require_once(): Failed opening required 'LOJAAUTOMATICA_INClist_table.php' (include_path='.:/usr/share/php') in wp-content/plugins/loja-automatica/admin/admin.php on line 7

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Please take a look at the following user-side issues
    • > GET request to /wp-admin/admin.php?page=lojaautomatica-add-new
    • > Javascript (severe) in unknown
    /wp-content/plugins/loja-automatica/js/custom.js?ver=1.0.0 28:33 Uncaught TypeError: $lojaautomatica(...).live is not a function
    • > GET request to /wp-admin/admin.php?page=lojaautomatica-add-new
    • > Network (severe)
    http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20xml%20where%20url%3D%27http%3A%2F%2Fwww.mercadolivre.com.br%2Fjm%2FcategsXml%3Fas_site_id%3DMLB%26as_max_level%3D1%26as_categ_id%3D%27%20AND%20itemPath%3D%27response.categories.category%27&format=json&callback= - Failed to load resource: net::ERR_NAME_NOT_RESOLVED

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Plugin Name: Please specify the plugin name on the first line ( === loja-automatica === )
Please take inspiration from this readme.txt

loja-automatica/loja-automatica.php 92% from 13 tests

The primary PHP file in "Loja Automática" version 1.0.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 258 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin1,337 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP102743321,198
JavaScript23723117
CSS16022

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity22.00
▷ Minimum class complexity12.00
▷ Maximum class complexity35.00
Average method complexity3.17
▷ Minimum method complexity1.00
▷ Maximum method complexity12.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods30
▷ Static methods00.00%
▷ Public methods2686.67%
▷ Protected methods00.00%
▷ Private methods413.33%
Functions36
▷ Named functions36100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.11MB with 0.07MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/banner-772x250.png102.97KB29.42KB▼ 71.43%
css/images/icons32.png14.31KB7.24KB▼ 49.36%