10% simple-photo-feed

Code Review | Simple Photo Feed for Instagram

WordPress plugin Simple Photo Feed for Instagram scored10%from 54 tests.

About plugin

  • Plugin page: simple-photo-feed
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1.1
  • WordPress version: 6.3.1
  • First release: Aug 17, 2022
  • Latest release: Dec 13, 2022
  • Number of updates: 5
  • Update frequency: every 23.8 days
  • Top authors: pattihis (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /704 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
These installer errors require your attention
  • The plugin did not install without errors
    • > Notice in wp-content/plugins/simple-photo-feed/includes/class-simple-photo-feed.php+81
    Undefined index: token

Server metrics [RAM: ▲0.03MB] [CPU: ▼5.20ms] Passed 4 tests

A check of server-side resources used by Simple Photo Feed for Instagram
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0337.25 ▼5.99
Dashboard /wp-admin3.33 ▲0.0345.77 ▼3.93
Posts /wp-admin/edit.php3.38 ▲0.0346.02 ▲0.02
Add New Post /wp-admin/post-new.php5.93 ▲0.0580.57 ▼10.90
Media Library /wp-admin/upload.php3.25 ▲0.0334.15 ▲4.58

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 22 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
spf_main_settings
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Simple Photo Feed for Instagram
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,821 ▲8614.80 ▲0.441.76 ▼0.0839.62 ▼9.05
Dashboard /wp-admin2,225 ▲345.81 ▲0.9199.54 ▼10.4038.62 ▼7.95
Posts /wp-admin/edit.php2,108 ▲192.01 ▼0.1739.05 ▲3.9135.04 ▼0.68
Add New Post /wp-admin/post-new.php1,540 ▲2618.35 ▲0.75596.44 ▼83.6654.01 ▼3.19
Media Library /wp-admin/upload.php1,410 ▲194.28 ▲0.1299.01 ▼1.0942.50 ▼0.96

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 2× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/simple-photo-feed/public/partials/simple-photo-feed-public-display.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Simple_Photo_Feed_Admin' not found in wp-content/plugins/simple-photo-feed/admin/partials/simple-photo-feed-admin-display.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: social, photo gallery, embed, feed, instagram

simple-photo-feed/simple-photo-feed.php Passed 13 tests

The primary PHP file in "Simple Photo Feed for Instagram" version 1.0.2 is used by WordPress to initiate all plugin functionality
137 characters long description:
Simple Photo Feed for Instagram provides an easy way to connect to your Instagram account and display your photos in your WordPress site.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin946 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP13211636673
CSS2363205
JavaScript15068

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity7.00
▷ Minimum class complexity1.00
▷ Maximum class complexity22.00
Average method complexity2.12
▷ Minimum method complexity1.00
▷ Maximum method complexity9.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods43
▷ Static methods24.65%
▷ Public methods3888.37%
▷ Protected methods00.00%
▷ Private methods511.63%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG files were detected