Guest User

Untitled

a guest
Nov 15th, 2018
111
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. public function getJsonConfig()
  2. * Parse swatch labels for template
  3. *
  4. * @codeCoverageIgnore
  5. * @param null $swatchStoreValue //Remove
  6. * @return string //Remove
  7. * @param null|array $swatchStoreValue //Add
  8. * @return null|array //Add
  9. */
  10. protected function reformatSwatchLabels($swatchStoreValue = null)
  11. {
  12. if ($swatchStoreValue === null) {
  13. return;
  14. }
  15. $newSwatch = ''; // Remove
  16. $newSwatch = []; //Add
  17. foreach ($swatchStoreValue as $key => $value) {
  18. if ($value[0] == '#') {
  19. $newSwatch[$key] = 'background: '.$value;
Add Comment
Please, Sign In to add comment