Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Sweep Rules] Refactor large functions in view files #73

Merged
merged 4 commits into from
Jun 6, 2024

Conversation

sweep-ai[bot]
Copy link
Contributor

@sweep-ai sweep-ai bot commented Mar 11, 2024

PR Feedback (click)

  • 馃憤 Sweep Did Well
  • 馃憥 Sweep Needs Improvement

I created this PR to address this rule:

"Refactor large functions to be more modular."

Description

This PR refactors the large functions in the view files resources/views/site_settings/edit.blade.php and resources/views/site_settings/index.blade.php to improve modularity and code organization.

Summary of Changes

  • Created a new blade file resources/views/site_settings/_form.blade.php to separate the form HTML code for editing site settings.
  • Updated resources/views/site_settings/edit.blade.php to include the form HTML code from _form.blade.php using the @include directive.
  • Removed the form HTML code from resources/views/site_settings/edit.blade.php.
  • Created a new blade file resources/views/site_settings/_table_row.blade.php to separate the HTML code for a single row in the site settings table.
  • Updated resources/views/site_settings/index.blade.php to include the table row HTML code from _table_row.blade.php using the @include directive.
  • Removed the table row HTML code from resources/views/site_settings/index.blade.php.

These changes improve modularity by breaking down the large functions into smaller components or partials, making the code more maintainable and easier to understand.

Copy link
Contributor Author

sweep-ai bot commented Mar 11, 2024

Rollback Files For Sweep

  • Rollback changes to resources/views/site_settings/_form.blade.php
  • Rollback changes to resources/views/site_settings/_form.blade.php
  • Rollback changes to resources/views/site_settings/edit.blade.php
  • Rollback changes to resources/views/site_settings/edit.blade.php
  • Rollback changes to resources/views/site_settings/index.blade.php
  • Rollback changes to resources/views/site_settings/index.blade.php
  • Rollback changes to resources/views/site_settings/_table_row.blade.php
  • Rollback changes to resources/views/site_settings/_table_row.blade.php

@sweep-ai sweep-ai bot added the sweep label Mar 11, 2024
@curtisdelicata curtisdelicata merged commit d968bb4 into main Jun 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant