84% easy-fc

Code Review | Easy Flashcards

WordPress plugin Easy Flashcards scored84%from 54 tests.

About plugin

  • Plugin page: easy-fc
  • Plugin version: 1.0
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-5.5.3
  • WordPress version: 6.3.1
  • First release: Dec 4, 2020
  • Latest release: Dec 5, 2020
  • Number of updates: 8
  • Update frequency: every 29.4 days
  • Top authors: florinmuscalu (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /439 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
This plugin's installer ran successfully

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

A check of server-side resources used by Easy Flashcards
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0335.19 ▼6.67
Dashboard /wp-admin3.35 ▲0.0044.11 ▼19.46
Posts /wp-admin/edit.php3.40 ▲0.0446.70 ▼0.46
Add New Post /wp-admin/post-new.php5.93 ▲0.0490.10 ▼0.86
Media Library /wp-admin/upload.php3.27 ▲0.0435.51 ▲1.52

Server storage [IO: ▲0.03MB] [DB: ▲0.07MB] Passed 3 tests

Filesystem and database footprint
No storage issues were detected
Filesystem: 4 new files
Database: no new tables, 23 new options
New WordPress options
easyfc_latest_try
theysaidso_admin_options
easyfc_correct_answers_text
widget_theysaidso_widget
easyfc_questions_total
easyfc_questions_text
widget_recent-comments
widget_recent-posts
easyfc_yes_btn
easyfc_reset_btn
...

Browser metrics Passed 4 tests

Checking browser requirements for Easy Flashcards
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,833 ▲8714.63 ▲0.281.70 ▼0.0438.66 ▼5.18
Dashboard /wp-admin2,207 ▲305.60 ▲0.0292.00 ▼10.1140.93 ▼2.68
Posts /wp-admin/edit.php2,112 ▲122.02 ▲0.0140.04 ▲2.0436.54 ▲3.82
Add New Post /wp-admin/post-new.php1,536 ▲1023.23 ▼0.31580.14 ▼85.9355.47 ▲2.64
Media Library /wp-admin/upload.php1,412 ▲94.18 ▼0.0196.31 ▼0.0339.98 ▼1.09

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • The uninstall procedure has failed, leaving 23 options in the database
    • easyfc_repeat_wrong_text
    • db_upgraded
    • easyfc_repeat_all_text
    • easyfc_reset_btn
    • easyfc_back_textsize
    • widget_recent-comments
    • easyfc_correct_all_text
    • easyfc_front_textsize
    • easyfc_questions_text
    • theysaidso_admin_options
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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 fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/easy-fc/easyfc.php:143

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
1 plugin tags: flashcads

easy-fc/easyfc.php 92% from 13 tests

The primary PHP file in "Easy Flashcards" version 1.0 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("easy-fc.php" instead of "easyfc.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin657 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP13916258
CSS1265249
JavaScript13212150

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.19
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There were not PNG files found in your plugin