Code Duplication    Length = 11-11 lines in 2 locations

src/PlaygroundGame/Entity/Game.php 2 locations

@@ 938-948 (lines=11) @@
935
     * @param string $step
936
     * @return string
937
     */
938
    public function previousStep($step = null)
939
    {
940
        $steps = $this->getStepsArray();
941
        $key = array_search($step, $steps);
942
943
        if (is_int($key) && $key > 0) {
944
            return $steps[$key-1];
945
        }
946
947
        return false;
948
    }
949
950
    /**
951
     * This method returns the next step in the game workflow
@@ 955-965 (lines=11) @@
952
     * @param string $step
953
     * @return string
954
     */
955
    public function nextStep($step = null)
956
    {
957
        $steps = $this->getStepsArray();
958
        $key = array_search($step, $steps);
959
960
        if (is_int($key) && $key < count($steps)-1) {
961
            return $steps[$key+1];
962
        }
963
964
        return false;
965
    }
966
967
    /**
968
     * @return string $stepsViews