Code Duplication    Length = 4-6 lines in 2 locations

classes/models/FrmForm.php 2 locations

@@ 562-565 (lines=4) @@
559
560
        $results = FrmDb::get_row( $table_name, $where );
561
562
		if ( isset( $results->options ) ) {
563
			FrmDb::set_cache( $results->id, $results, 'frm_form' );
564
			$results->options = maybe_unserialize( $results->options );
565
        }
566
		return stripslashes_deep( $results );
567
    }
568
@@ 591-596 (lines=6) @@
588
			$results = $wpdb->get_results( $query ); // WPCS: unprepared SQL ok.
589
		}
590
591
		if ( $results ) {
592
			foreach ( $results as $result ) {
593
				FrmDb::set_cache( $result->id, $result, 'frm_form' );
594
				$result->options = maybe_unserialize( $result->options );
595
			}
596
		}
597
598
		if ( $limit == ' LIMIT 1' || $limit == 1 ) {
599
			// return the first form object if we are only getting one form